home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 2 / Amiga Tools 2.iso / tex / macros / source / contrib / textmerg / textmerg.dtx < prev    next >
LaTeX Document  |  1995-03-10  |  27.4 KB

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: LaTeX Document (document/latex).

ConfidenceProgramDetectionMatch TypeSupport
100% dexvert LaTeX Document (document/latex) magic Supported
99% dexvert Texinfo Document (document/texInfo) magic Supported
1% dexvert Text File (text/txt) fallback Supported
100% file LaTeX document text default
99% file TeX document text default
98% file LaTeX document, ASCII text default
83% TrID LaTeX 2e document (with rem) default
16% TrID Gerber format default (weak)
100% checkBytes Printable ASCII default
100% perlTextCheck Likely Text (Perl) default
100% detectItEasy Format: plain text[LF] default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 25 20 20 20 20 5c 69 66 | 66 61 6c 73 65 20 6d 65 |% \if|false me|
|00000010| 74 61 2d 63 6f 6d 6d 65 | 6e 74 0a 25 20 20 20 20 |ta-comme|nt.% |
|00000020| 5c 62 65 67 69 6e 7b 6d | 61 63 72 6f 63 6f 64 65 |\begin{m|acrocode|
|00000030| 7d 0a 25 3c 2a 74 65 78 | 74 6d 65 72 67 7c 70 6c |}.%<*tex|tmerg|pl|
|00000040| 61 69 6e 3e 0a 5c 64 65 | 66 5c 66 69 6c 65 76 65 |ain>.\de|f\fileve|
|00000050| 72 73 69 6f 6e 7b 32 2e | 30 31 7d 0a 5c 64 65 66 |rsion{2.|01}.\def|
|00000060| 5c 66 69 6c 65 64 61 74 | 65 7b 31 39 39 34 2f 30 |\filedat|e{1994/0|
|00000070| 36 2f 32 30 7d 0a 5c 64 | 65 66 5c 66 69 6c 65 6e |6/20}.\d|ef\filen|
|00000080| 61 6d 65 7b 74 65 78 74 | 6d 65 72 67 2e 64 74 78 |ame{text|merg.dtx|
|00000090| 7d 0a 5c 64 65 66 5c 43 | 6f 70 79 72 69 67 68 74 |}.\def\C|opyright|
|000000a0| 7b 43 6f 70 79 72 69 67 | 68 74 20 28 43 29 20 31 |{Copyrig|ht (C) 1|
|000000b0| 39 39 32 2c 31 39 39 34 | 20 4d 69 6b 65 20 50 69 |992,1994| Mike Pi|
|000000c0| 66 66 2c 20 55 6e 69 76 | 65 72 73 69 74 79 20 6f |ff, Univ|ersity o|
|000000d0| 66 20 53 68 65 66 66 69 | 65 6c 64 2c 20 45 6e 67 |f Sheffi|eld, Eng|
|000000e0| 6c 61 6e 64 7d 0a 25 3c | 2f 74 65 78 74 6d 65 72 |land}.%<|/textmer|
|000000f0| 67 7c 70 6c 61 69 6e 3e | 0a 25 20 20 20 20 5c 65 |g|plain>|.% \e|
|00000100| 6e 64 7b 6d 61 63 72 6f | 63 6f 64 65 7d 0a 25 0a |nd{macro|code}.%.|
|00000110| 25 59 6f 75 20 61 72 65 | 20 6e 6f 74 20 61 6c 6c |%You are| not all|
|00000120| 6f 77 65 64 20 74 6f 20 | 63 68 61 6e 67 65 20 74 |owed to |change t|
|00000130| 68 69 73 20 66 69 6c 65 | 2e 0a 25 0a 25 59 6f 75 |his file|..%.%You|
|00000140| 20 61 72 65 20 4e 4f 54 | 20 41 4c 4c 4f 57 45 44 | are NOT| ALLOWED|
|00000150| 20 74 6f 20 64 69 73 74 | 72 69 62 75 74 65 20 74 | to dist|ribute t|
|00000160| 68 69 73 20 66 69 6c 65 | 20 61 6c 6f 6e 65 2e 20 |his file| alone. |
|00000170| 20 59 6f 75 20 61 72 65 | 20 4e 4f 54 0a 25 41 4c | You are| NOT.%AL|
|00000180| 4c 4f 57 45 44 20 74 6f | 20 74 61 6b 65 20 6d 6f |LOWED to| take mo|
|00000190| 6e 65 79 20 66 6f 72 20 | 74 68 65 20 64 69 73 74 |ney for |the dist|
|000001a0| 72 69 62 75 74 69 6f 6e | 20 6f 72 20 75 73 65 20 |ribution| or use |
|000001b0| 6f 66 20 74 68 69 73 0a | 25 66 69 6c 65 20 65 78 |of this.|%file ex|
|000001c0| 63 65 70 74 20 66 6f 72 | 20 61 20 6e 6f 6d 69 6e |cept for| a nomin|
|000001d0| 61 6c 20 63 68 61 72 67 | 65 20 66 6f 72 20 63 6f |al charg|e for co|
|000001e0| 70 79 69 6e 67 20 65 74 | 63 2e 0a 25 0a 25 50 6c |pying et|c..%.%Pl|
|000001f0| 65 61 73 65 20 61 64 64 | 72 65 73 73 20 61 6e 79 |ease add|ress any|
|00000200| 20 70 72 6f 62 6c 65 6d | 73 20 74 6f 3a 0a 25 0a | problem|s to:.%.|
|00000210| 25 4d 2e 50 69 66 66 40 | 73 68 65 66 2e 61 63 2e |%M.Piff@|shef.ac.|
|00000220| 75 6b 0a 25 0a 25 46 6f | 72 20 75 70 64 61 74 65 |uk.%.%Fo|r update|
|00000230| 73 2c 20 63 6f 6e 74 61 | 63 74 20 79 6f 75 72 20 |s, conta|ct your |
|00000240| 6e 65 61 72 65 73 74 20 | 43 54 41 4e 20 73 69 74 |nearest |CTAN sit|
|00000250| 65 2e 0a 25 0a 25 20 20 | 20 20 5c 66 69 0a 25 0a |e..%.% | \fi.%.|
|00000260| 25 20 5c 63 68 61 6e 67 | 65 73 7b 32 2e 30 31 7d |% \chang|es{2.01}|
|00000270| 7b 31 39 39 34 2f 30 36 | 2f 32 30 7d 7b 46 69 72 |{1994/06|/20}{Fir|
|00000280| 73 74 20 76 65 72 73 69 | 6f 6e 20 66 6f 72 20 4c |st versi|on for L|
|00000290| 61 54 65 58 32 65 7d 0a | 25 0a 25 5c 43 68 65 63 |aTeX2e}.|%.%\Chec|
|000002a0| 6b 53 75 6d 7b 33 34 39 | 7d 0a 25 0a 25 5c 74 69 |kSum{349|}.%.%\ti|
|000002b0| 74 6c 65 7b 54 65 78 74 | 20 6d 65 72 67 65 73 20 |tle{Text| merges |
|000002c0| 69 6e 20 5c 54 65 58 5c | 20 61 6e 64 20 5c 4c 61 |in \TeX\| and \La|
|000002d0| 54 65 58 5c 74 68 61 6e | 6b 73 7b 54 68 69 73 20 |TeX\than|ks{This |
|000002e0| 61 72 74 69 63 6c 65 20 | 6f 72 69 67 69 6e 61 6c |article |original|
|000002f0| 6c 79 0a 25 61 70 70 65 | 61 72 65 64 20 69 6e 20 |ly.%appe|ared in |
|00000300| 54 55 47 62 6f 61 74 20 | 56 6f 6c 20 31 33 28 34 |TUGboat |Vol 13(4|
|00000310| 29 2c 20 31 39 39 32 2c | 20 70 35 31 38 2d 2d 35 |), 1992,| p518--5|
|00000320| 32 33 2e 7d 7d 0a 25 5c | 61 75 74 68 6f 72 7b 4d |23.}}.%\|author{M|
|00000330| 69 6b 65 20 50 69 66 66 | 7d 0a 25 5c 6d 61 6b 65 |ike Piff|}.%\make|
|00000340| 74 69 74 6c 65 0a 25 5c | 74 68 69 73 70 61 67 65 |title.%\|thispage|
|00000350| 73 74 79 6c 65 7b 68 65 | 61 64 69 6e 67 73 7d 0a |style{he|adings}.|
|00000360| 25 5c 62 65 67 69 6e 7b | 61 62 73 74 72 61 63 74 |%\begin{|abstract|
|00000370| 7d 0a 25 20 20 20 49 6e | 20 74 68 69 73 20 61 72 |}.% In| this ar|
|00000380| 74 69 63 6c 65 20 74 68 | 65 20 61 75 74 68 6f 72 |ticle th|e author|
|00000390| 20 65 78 70 6c 61 69 6e | 73 20 68 6f 77 20 74 6f | explain|s how to|
|000003a0| 20 64 6f 20 73 6f 6d 65 | 20 73 74 61 6e 64 61 72 | do some| standar|
|000003b0| 64 0a 25 20 20 20 61 6e | 64 20 6e 6f 74 20 73 6f |d.% an|d not so|
|000003c0| 20 73 74 61 6e 64 61 72 | 64 20 77 6f 72 64 20 70 | standar|d word p|
|000003d0| 72 6f 63 65 73 73 6f 72 | 20 74 65 78 74 20 6d 65 |rocessor| text me|
|000003e0| 72 67 65 73 20 69 6e 20 | 5c 54 65 58 5c 20 64 6f |rges in |\TeX\ do|
|000003f0| 63 75 6d 65 6e 74 73 2c | 0a 25 20 20 20 75 73 69 |cuments,|.% usi|
|00000400| 6e 67 20 6e 6f 20 6f 74 | 68 65 72 20 74 6f 6f 6c |ng no ot|her tool|
|00000410| 73 20 74 68 61 6e 20 5c | 54 65 58 5c 20 69 74 73 |s than \|TeX\ its|
|00000420| 65 6c 66 2e 0a 25 20 20 | 20 41 20 63 6f 6d 6d 6f |elf..% | A commo|
|00000430| 6e 20 61 70 70 6c 69 63 | 61 74 69 6f 6e 20 69 73 |n applic|ation is|
|00000440| 20 74 6f 20 74 68 65 20 | 6d 61 69 6c 20 6d 65 72 | to the |mail mer|
|00000450| 67 65 20 6f 72 20 66 6f | 72 6d 20 6c 65 74 74 65 |ge or fo|rm lette|
|00000460| 72 2c 0a 25 20 20 20 77 | 68 65 72 65 20 6e 61 6d |r,.% w|here nam|
|00000470| 65 73 20 61 6e 64 20 61 | 64 64 72 65 73 73 65 73 |es and a|ddresses|
|00000480| 20 61 72 65 0a 25 20 20 | 20 73 74 6f 72 65 64 20 | are.% | stored |
|00000490| 69 6e 20 61 20 66 69 6c | 65 2c 20 74 6f 67 65 74 |in a fil|e, toget|
|000004a0| 68 65 72 20 77 69 74 68 | 20 6f 74 68 65 72 20 62 |her with| other b|
|000004b0| 69 74 73 20 6f 66 20 69 | 6e 66 6f 72 6d 61 74 69 |its of i|nformati|
|000004c0| 6f 6e 2c 20 61 6e 64 20 | 61 20 73 74 61 6e 64 61 |on, and |a standa|
|000004d0| 72 64 0a 25 20 20 20 6c | 65 74 74 65 72 20 77 69 |rd.% l|etter wi|
|000004e0| 74 68 20 76 61 72 69 61 | 62 6c 65 20 66 69 65 6c |th varia|ble fiel|
|000004f0| 64 73 20 65 6d 62 65 64 | 64 65 64 20 69 6e 20 69 |ds embed|ded in i|
|00000500| 74 20 69 73 20 63 75 73 | 74 6f 6d 69 7a 65 64 20 |t is cus|tomized |
|00000510| 66 6f 72 20 65 76 65 72 | 79 20 6e 61 6d 65 0a 25 |for ever|y name.%|
|00000520| 20 20 20 66 72 6f 6d 20 | 74 68 69 73 20 66 69 6c | from |this fil|
|00000530| 65 2e 0a 25 20 20 20 41 | 6e 6f 74 68 65 72 20 61 |e..% A|nother a|
|00000540| 70 70 6c 69 63 61 74 69 | 6f 6e 20 69 73 20 74 6f |pplicati|on is to|
|00000550| 20 74 68 65 20 70 72 65 | 74 74 79 2d 70 72 69 6e | the pre|tty-prin|
|00000560| 74 69 6e 67 20 6f 66 20 | 74 68 65 20 63 6f 6e 74 |ting of |the cont|
|00000570| 65 6e 74 73 20 6f 66 20 | 61 20 64 61 74 61 62 61 |ents of |a databa|
|00000580| 73 65 2e 0a 25 0a 25 20 | 20 20 54 68 65 20 6d 61 |se..%.% | The ma|
|00000590| 63 72 6f 73 20 64 65 73 | 63 72 69 62 65 64 20 69 |cros des|cribed i|
|000005a0| 6e 20 7c 74 65 78 74 6d | 65 72 67 2e 73 74 79 7c |n |textm|erg.sty||
|000005b0| 20 77 6f 72 6b 20 65 71 | 75 61 6c 6c 79 0a 25 20 | work eq|ually.% |
|000005c0| 20 20 69 6e 20 62 6f 74 | 68 20 70 6c 61 69 6e 20 | in bot|h plain |
|000005d0| 5c 54 65 58 5c 20 61 6e | 64 20 5c 4c 61 54 65 58 |\TeX\ an|d \LaTeX|
|000005e0| 2e 20 48 6f 77 65 76 65 | 72 2c 20 74 68 69 73 20 |. Howeve|r, this |
|000005f0| 68 61 73 20 6d 65 61 6e | 74 20 68 65 61 76 79 20 |has mean|t heavy |
|00000600| 75 73 65 0a 25 20 20 20 | 6f 66 20 7c 5c 64 65 66 |use.% |of |\def|
|00000610| 7c 20 77 68 65 72 65 20 | 7c 5c 6e 65 77 63 6f 6d || where ||\newcom|
|00000620| 6d 61 6e 64 7c 20 77 6f | 75 6c 64 20 68 61 76 65 |mand| wo|uld have|
|00000630| 20 62 65 65 6e 20 70 72 | 65 66 65 72 61 62 6c 65 | been pr|eferable|
|00000640| 2e 0a 25 5c 65 6e 64 7b | 61 62 73 74 72 61 63 74 |..%\end{|abstract|
|00000650| 7d 0a 25 0a 25 5c 74 61 | 62 6c 65 6f 66 63 6f 6e |}.%.%\ta|bleofcon|
|00000660| 74 65 6e 74 73 0a 25 0a | 25 5c 73 65 63 74 69 6f |tents.%.|%\sectio|
|00000670| 6e 7b 49 6e 74 72 6f 64 | 75 63 74 69 6f 6e 7d 0a |n{Introd|uction}.|
|00000680| 25 49 74 20 69 73 20 6f | 66 74 65 6e 20 73 61 69 |%It is o|ften sai|
|00000690| 64 20 74 68 61 74 20 61 | 6c 74 68 6f 75 67 68 20 |d that a|lthough |
|000006a0| 5c 4c 61 54 65 58 5c 20 | 69 73 20 67 6f 6f 64 20 |\LaTeX\ |is good |
|000006b0| 61 74 20 74 79 70 65 73 | 65 74 74 69 6e 67 0a 25 |at types|etting.%|
|000006c0| 6d 61 74 68 65 6d 61 74 | 69 63 73 2c 20 69 74 20 |mathemat|ics, it |
|000006d0| 69 73 20 77 68 6f 6c 6c | 79 20 75 6e 73 75 69 74 |is wholl|y unsuit|
|000006e0| 61 62 6c 65 20 66 6f 72 | 20 63 6f 6d 6d 6f 6e 20 |able for| common |
|000006f0| 77 6f 72 64 20 70 72 6f | 63 65 73 73 6f 72 20 66 |word pro|cessor f|
|00000700| 75 6e 63 74 69 6f 6e 73 | 0a 25 73 75 63 68 20 61 |unctions|.%such a|
|00000710| 73 20 6d 61 69 6c 20 6d | 65 72 67 65 73 2e 0a 25 |s mail m|erges..%|
|00000720| 54 68 65 20 6c 61 74 74 | 65 72 20 61 72 65 20 65 |The latt|er are e|
|00000730| 61 73 79 20 74 6f 20 61 | 63 68 69 65 76 65 20 69 |asy to a|chieve i|
|00000740| 6e 20 6d 6f 73 74 20 6f | 72 64 69 6e 61 72 79 20 |n most o|rdinary |
|00000750| 77 6f 72 64 20 70 72 6f | 63 65 73 73 6f 72 73 2c |word pro|cessors,|
|00000760| 0a 25 62 75 74 20 69 6e | 20 69 74 73 20 72 61 77 |.%but in| its raw|
|00000770| 20 73 74 61 74 65 20 5c | 4c 61 54 65 58 5c 20 69 | state \|LaTeX\ i|
|00000780| 73 20 69 6e 63 61 70 61 | 62 6c 65 20 6f 66 20 64 |s incapa|ble of d|
|00000790| 6f 69 6e 67 20 61 20 6d | 61 69 6c 20 6d 65 72 67 |oing a m|ail merg|
|000007a0| 65 2c 20 6f 72 2c 20 69 | 6e 64 65 65 64 2c 20 6f |e, or, i|ndeed, o|
|000007b0| 66 0a 25 67 65 6e 65 72 | 61 74 69 6e 67 20 74 68 |f.%gener|ating th|
|000007c0| 65 20 73 61 6d 65 20 62 | 6c 6f 63 6b 20 6f 66 20 |e same b|lock of |
|000007d0| 74 65 78 74 20 6f 76 65 | 72 20 61 6e 64 20 6f 76 |text ove|r and ov|
|000007e0| 65 72 20 61 67 61 69 6e | 20 62 75 74 20 77 69 74 |er again| but wit|
|000007f0| 68 20 64 69 66 66 65 72 | 65 6e 74 0a 25 70 61 72 |h differ|ent.%par|
|00000800| 61 6d 65 74 65 72 73 20 | 69 6e 20 65 61 63 68 20 |ameters |in each |
|00000810| 62 6c 6f 63 6b 2c 20 74 | 68 6f 73 65 20 70 61 72 |block, t|hose par|
|00000820| 61 6d 65 74 65 72 73 20 | 68 61 76 69 6e 67 20 62 |ameters |having b|
|00000830| 65 65 6e 20 72 65 61 64 | 20 66 72 6f 6d 20 61 20 |een read| from a |
|00000840| 73 75 62 73 69 64 69 61 | 72 79 0a 25 6d 65 72 67 |subsidia|ry.%merg|
|00000850| 65 20 66 69 6c 65 2e 0a | 25 54 68 65 20 6c 61 74 |e file..|%The lat|
|00000860| 74 65 72 20 66 69 6c 65 | 20 6d 69 67 68 74 20 70 |ter file| might p|
|00000870| 6f 73 73 69 62 6c 79 20 | 62 65 20 74 68 65 20 6f |ossibly |be the o|
|00000880| 75 74 70 75 74 20 66 72 | 6f 6d 20 61 20 64 61 74 |utput fr|om a dat|
|00000890| 61 62 61 73 65 20 6f 72 | 20 61 6e 79 20 6f 74 68 |abase or| any oth|
|000008a0| 65 72 0a 25 70 72 6f 67 | 72 61 6d 2e 0a 25 0a 25 |er.%prog|ram..%.%|
|000008b0| 54 68 69 73 20 61 72 74 | 69 63 6c 65 20 61 69 6d |This art|icle aim|
|000008c0| 73 20 74 6f 20 73 68 6f | 77 20 74 68 65 20 72 65 |s to sho|w the re|
|000008d0| 61 64 65 72 20 74 68 61 | 74 20 73 75 63 68 20 61 |ader tha|t such a|
|000008e0| 20 72 65 70 65 74 69 74 | 69 76 65 20 74 61 73 6b | repetit|ive task|
|000008f0| 20 6e 65 65 64 20 6e 6f | 74 20 62 65 0a 25 61 73 | need no|t be.%as|
|00000900| 20 64 69 66 66 69 63 75 | 6c 74 20 61 73 20 69 74 | difficu|lt as it|
|00000910| 20 61 74 20 66 69 72 73 | 74 20 61 70 70 65 61 72 | at firs|t appear|
|00000920| 73 2e 20 49 6e 20 5c 54 | 65 58 2c 20 69 74 20 69 |s. In \T|eX, it i|
|00000930| 73 20 70 6f 73 73 69 62 | 6c 65 20 74 6f 20 68 69 |s possib|le to hi|
|00000940| 64 65 20 6d 61 6e 79 0a | 25 64 65 74 61 69 6c 73 |de many.|%details|
|00000950| 20 6f 66 20 61 20 66 61 | 63 69 6c 69 74 79 20 69 | of a fa|cility i|
|00000960| 6e 73 69 64 65 20 61 20 | 73 75 62 73 69 64 69 61 |nside a |subsidia|
|00000970| 72 79 20 73 74 79 6c 65 | 20 66 69 6c 65 2c 20 73 |ry style| file, s|
|00000980| 6f 20 74 68 61 74 20 74 | 68 65 20 75 73 65 72 20 |o that t|he user |
|00000990| 69 73 0a 25 75 6e 61 77 | 61 72 65 20 6f 66 20 77 |is.%unaw|are of w|
|000009a0| 68 61 74 20 66 65 61 72 | 66 75 6c 20 70 72 6f 63 |hat fear|ful proc|
|000009b0| 65 73 73 65 73 20 61 72 | 65 20 67 6f 69 6e 67 20 |esses ar|e going |
|000009c0| 6f 6e 20 69 6e 20 74 68 | 65 20 62 61 63 6b 67 72 |on in th|e backgr|
|000009d0| 6f 75 6e 64 2e 0a 25 49 | 74 20 69 73 20 74 68 65 |ound..%I|t is the|
|000009e0| 6e 20 70 6f 73 73 69 62 | 6c 65 20 74 6f 20 70 72 |n possib|le to pr|
|000009f0| 65 73 65 6e 74 20 74 68 | 65 20 65 6e 64 2d 75 73 |esent th|e end-us|
|00000a00| 65 72 20 77 69 74 68 20 | 61 6e 20 65 78 74 72 65 |er with |an extre|
|00000a10| 6d 65 6c 79 20 73 69 6d | 70 6c 65 0a 25 69 6e 74 |mely sim|ple.%int|
|00000a20| 65 72 66 61 63 65 2c 20 | 70 65 72 68 61 70 73 20 |erface, |perhaps |
|00000a30| 73 69 6d 70 6c 65 72 20 | 61 6e 64 20 6d 6f 72 65 |simpler |and more|
|00000a40| 20 70 6f 77 65 72 66 75 | 6c 20 74 68 61 6e 20 69 | powerfu|l than i|
|00000a50| 73 20 61 76 61 69 6c 61 | 62 6c 65 20 69 6e 20 6f |s availa|ble in o|
|00000a60| 74 68 65 72 0a 25 73 79 | 73 74 65 6d 73 2e 0a 25 |ther.%sy|stems..%|
|00000a70| 0a 25 49 6e 20 65 61 72 | 6c 69 65 72 20 54 55 47 |.%In ear|lier TUG|
|00000a80| 62 6f 61 74 20 61 72 74 | 69 63 6c 65 73 0a 25 5c |boat art|icles.%\|
|00000a90| 63 69 74 65 7b 42 65 6c | 6c 3a 54 42 38 2d 31 2d |cite{Bel|l:TB8-1-|
|00000aa0| 35 34 2c 47 61 72 61 76 | 65 6c 6c 69 3a 54 42 38 |54,Garav|elli:TB8|
|00000ab0| 2d 31 2d 35 33 2c 4c 65 | 65 3a 54 42 37 2d 33 2d |-1-53,Le|e:TB7-3-|
|00000ac0| 31 38 37 2c 25 0a 25 4d | 63 4b 69 6e 73 74 72 79 |187,%.%M|cKinstry|
|00000ad0| 3a 54 42 38 2d 31 2d 36 | 30 7d 20 69 74 20 77 61 |:TB8-1-6|0} it wa|
|00000ae0| 73 20 73 68 6f 77 6e 20 | 68 6f 77 20 61 20 73 74 |s shown |how a st|
|00000af0| 61 6e 64 61 72 64 20 6c | 65 74 74 65 72 20 63 6f |andard l|etter co|
|00000b00| 75 6c 64 20 62 65 0a 25 | 63 75 73 74 6f 6d 69 7a |uld be.%|customiz|
|00000b10| 65 64 20 62 79 20 61 64 | 64 69 6e 67 20 6e 61 6d |ed by ad|ding nam|
|00000b20| 65 73 20 61 6e 64 20 61 | 64 64 72 65 73 73 65 73 |es and a|ddresses|
|00000b30| 20 66 72 6f 6d 20 61 20 | 73 65 70 61 72 61 74 65 | from a |separate|
|00000b40| 20 66 69 6c 65 2e 20 49 | 20 61 69 6d 20 74 6f 20 | file. I| aim to |
|00000b50| 73 68 6f 77 0a 25 74 68 | 61 74 20 69 74 20 69 73 |show.%th|at it is|
|00000b60| 20 70 6f 73 73 69 62 6c | 65 20 74 6f 20 61 63 68 | possibl|e to ach|
|00000b70| 69 65 76 65 20 66 61 72 | 20 6d 6f 72 65 20 74 68 |ieve far| more th|
|00000b80| 61 6e 20 74 68 69 73 20 | 77 69 74 68 20 61 20 66 |an this |with a f|
|00000b90| 61 69 72 6c 79 20 63 6f | 6d 70 61 63 74 0a 25 62 |airly co|mpact.%b|
|00000ba0| 75 74 20 67 65 6e 65 72 | 61 6c 20 73 65 74 20 6f |ut gener|al set o|
|00000bb0| 66 20 6d 61 63 72 6f 73 | 2e 0a 25 0a 25 5c 73 65 |f macros|..%.%\se|
|00000bc0| 63 74 69 6f 6e 7b 41 20 | 73 69 6d 70 6c 65 20 65 |ction{A |simple e|
|00000bd0| 78 61 6d 70 6c 65 7d 0a | 25 53 75 70 70 6f 73 65 |xample}.|%Suppose|
|00000be0| 20 74 68 61 74 20 77 65 | 20 68 61 76 65 20 61 20 | that we| have a |
|00000bf0| 6c 69 73 74 20 6f 66 20 | 73 74 75 64 65 6e 74 20 |list of |student |
|00000c00| 6e 61 6d 65 73 20 61 6e | 64 20 65 78 61 6d 69 6e |names an|d examin|
|00000c10| 61 74 69 6f 6e 20 67 72 | 61 64 65 73 2c 20 6f 6e |ation gr|ades, on|
|00000c20| 65 0a 25 70 65 72 20 73 | 74 75 64 65 6e 74 2c 20 |e.%per s|tudent, |
|00000c30| 61 6e 64 20 74 68 61 74 | 20 77 65 20 77 69 73 68 |and that| we wish|
|00000c40| 20 74 6f 20 73 65 6e 64 | 20 61 20 6c 65 74 74 65 | to send| a lette|
|00000c50| 72 20 74 6f 20 65 61 63 | 68 20 73 74 75 64 65 6e |r to eac|h studen|
|00000c60| 74 20 67 69 76 69 6e 67 | 0a 25 68 69 73 2f 68 65 |t giving|.%his/he|
|00000c70| 72 20 65 78 61 6d 20 67 | 72 61 64 65 2e 0a 25 57 |r exam g|rade..%W|
|00000c80| 65 20 6d 75 73 74 20 64 | 65 63 69 64 65 20 66 69 |e must d|ecide fi|
|00000c90| 72 73 74 20 77 68 61 74 | 20 62 69 74 73 20 6f 66 |rst what| bits of|
|00000ca0| 20 69 6e 66 6f 72 6d 61 | 74 69 6f 6e 20 6d 75 73 | informa|tion mus|
|00000cb0| 74 20 62 65 20 70 72 65 | 70 61 72 65 64 20 69 6e |t be pre|pared in|
|00000cc0| 0a 25 6f 75 72 20 73 75 | 62 73 69 64 69 61 72 79 |.%our su|bsidiary|
|00000cd0| 20 66 69 6c 65 2c 20 62 | 79 20 6c 6f 6f 6b 69 6e | file, b|y lookin|
|00000ce0| 67 20 61 74 20 61 6e 20 | 65 78 61 6d 70 6c 65 20 |g at an |example |
|00000cf0| 6c 65 74 74 65 72 20 61 | 6e 64 20 66 69 6e 64 69 |letter a|nd findi|
|00000d00| 6e 67 20 6f 75 74 20 77 | 68 69 63 68 0a 25 69 74 |ng out w|hich.%it|
|00000d10| 65 6d 73 20 63 68 61 6e | 67 65 20 66 72 6f 6d 20 |ems chan|ge from |
|00000d20| 6c 65 74 74 65 72 20 74 | 6f 20 6c 65 74 74 65 72 |letter t|o letter|
|00000d30| 2e 0a 25 0a 25 53 75 70 | 70 6f 73 65 20 74 68 61 |..%.%Sup|pose tha|
|00000d40| 74 20 6f 6e 65 20 69 6e | 73 74 61 6e 63 65 20 6f |t one in|stance o|
|00000d50| 66 20 6f 75 72 20 6c 65 | 74 74 65 72 20 69 73 20 |f our le|tter is |
|00000d60| 74 68 65 20 66 6f 6c 6c | 6f 77 69 6e 67 2c 0a 25 |the foll|owing,.%|
|00000d70| 61 20 20 5c 4c 61 54 65 | 58 5c 20 65 78 61 6d 70 |a \LaTe|X\ examp|
|00000d80| 6c 65 2e 0a 25 5c 62 65 | 67 69 6e 7b 76 65 72 62 |le..%\be|gin{verb|
|00000d90| 61 74 69 6d 7d 0a 25 5c | 62 65 67 69 6e 7b 6c 65 |atim}.%\|begin{le|
|00000da0| 74 74 65 72 7d 7b 4d 69 | 73 73 20 49 75 73 74 61 |tter}{Mi|ss Iusta|
|00000db0| 20 4d 6f 5c 5c 0a 25 20 | 20 20 33 34 20 57 69 6e | Mo\\.% | 34 Win|
|00000dc0| 63 68 65 73 74 65 72 20 | 52 6f 61 64 5c 5c 0a 25 |chester |Road\\.%|
|00000dd0| 20 20 20 53 68 65 66 66 | 69 65 6c 64 5c 5c 0a 25 | Sheff|ield\\.%|
|00000de0| 20 20 20 45 6e 67 6c 61 | 6e 64 7d 0a 25 20 20 20 | Engla|nd}.% |
|00000df0| 5c 6f 70 65 6e 69 6e 67 | 7b 44 65 61 72 20 4d 69 |\opening|{Dear Mi|
|00000e00| 73 73 20 4d 6f 2c 7d 0a | 25 20 20 20 54 68 69 73 |ss Mo,}.|% This|
|00000e10| 20 6c 65 74 74 65 72 20 | 69 73 20 74 6f 20 69 6e | letter |is to in|
|00000e20| 66 6f 72 6d 20 79 6f 75 | 0a 25 20 20 20 74 68 61 |form you|.% tha|
|00000e30| 74 20 79 6f 75 20 6f 62 | 74 61 69 6e 65 64 20 67 |t you ob|tained g|
|00000e40| 72 61 64 65 20 41 20 69 | 6e 0a 25 20 20 20 79 6f |rade A i|n.% yo|
|00000e50| 75 72 20 72 65 63 65 6e | 74 20 65 78 61 6d 69 6e |ur recen|t examin|
|00000e60| 61 74 69 6f 6e 73 2e 0a | 25 20 20 20 5c 63 6c 6f |ations..|% \clo|
|00000e70| 73 69 6e 67 7b 59 6f 75 | 72 73 20 66 61 69 74 68 |sing{You|rs faith|
|00000e80| 66 75 6c 6c 79 2c 7d 0a | 25 5c 65 6e 64 7b 6c 65 |fully,}.|%\end{le|
|00000e90| 74 74 65 72 7d 0a 25 5c | 65 6e 64 7b 76 65 72 62 |tter}.%\|end{verb|
|00000ea0| 61 74 69 6d 7d 0a 25 57 | 65 20 63 61 6e 20 73 65 |atim}.%W|e can se|
|00000eb0| 65 20 74 68 61 74 20 77 | 65 20 6e 65 65 64 20 74 |e that w|e need t|
|00000ec0| 6f 20 6b 6e 6f 77 20 74 | 68 65 20 73 74 75 64 65 |o know t|he stude|
|00000ed0| 6e 74 27 73 20 74 69 74 | 6c 65 2c 20 66 6f 72 65 |nt's tit|le, fore|
|00000ee0| 6e 61 6d 65 28 73 29 2c | 20 73 75 72 6e 61 6d 65 |name(s),| surname|
|00000ef0| 2c 0a 25 61 64 64 72 65 | 73 73 20 61 6e 64 20 67 |,.%addre|ss and g|
|00000f00| 72 61 64 65 20 74 6f 20 | 63 6f 6d 70 6f 73 65 20 |rade to |compose |
|00000f10| 73 75 63 68 20 61 20 6c | 65 74 74 65 72 2e 0a 25 |such a l|etter..%|
|00000f20| 0a 25 4f 6e 65 20 6f 66 | 20 74 68 65 20 73 69 6d |.%One of| the sim|
|00000f30| 70 6c 65 73 74 20 77 61 | 79 73 20 6f 66 20 61 63 |plest wa|ys of ac|
|00000f40| 68 69 65 76 69 6e 67 20 | 74 68 69 73 20 65 66 66 |hieving |this eff|
|00000f50| 65 63 74 20 69 73 20 74 | 6f 20 70 72 65 70 61 72 |ect is t|o prepar|
|00000f60| 65 20 61 20 66 69 6c 65 | 0a 25 77 69 74 68 20 6c |e a file|.%with l|
|00000f70| 69 6e 65 73 20 6f 66 20 | 74 68 65 20 66 6f 72 6d |ines of |the form|
|00000f80| 0a 25 5c 62 65 67 69 6e | 7b 76 65 72 62 61 74 69 |.%\begin|{verbati|
|00000f90| 6d 7d 0a 25 5c 4d 79 4c | 65 74 74 65 72 7b 4d 72 |m}.%\MyL|etter{Mr|
|00000fa0| 7d 2e 2e 2e 7b 43 7d 0a | 25 5c 65 6e 64 7b 76 65 |}...{C}.|%\end{ve|
|00000fb0| 72 62 61 74 69 6d 7d 0a | 25 66 6f 72 20 65 61 63 |rbatim}.|%for eac|
|00000fc0| 68 20 73 74 75 64 65 6e | 74 20 61 6e 64 20 74 68 |h studen|t and th|
|00000fd0| 65 6e 20 73 69 6d 70 6c | 79 20 7c 5c 69 6e 70 75 |en simpl|y |\inpu|
|00000fe0| 74 7c 20 69 74 20 69 6e | 74 6f 20 61 20 5c 4c 61 |t| it in|to a \La|
|00000ff0| 54 65 58 5c 20 66 69 6c | 65 20 69 6e 20 77 68 69 |TeX\ fil|e in whi|
|00001000| 63 68 0a 25 7c 5c 4d 79 | 4c 65 74 74 65 72 7c 20 |ch.%|\My|Letter| |
|00001010| 68 61 73 20 62 65 65 6e | 20 64 65 66 69 6e 65 64 |has been| defined|
|00001020| 20 61 73 20 68 61 76 69 | 6e 67 20 66 69 76 65 20 | as havi|ng five |
|00001030| 70 61 72 61 6d 65 74 65 | 72 73 2e 0a 25 41 20 70 |paramete|rs..%A p|
|00001040| 72 6f 62 6c 65 6d 20 77 | 69 74 68 20 74 68 69 73 |roblem w|ith this|
|00001050| 20 61 70 70 72 6f 61 63 | 68 20 69 73 20 74 68 61 | approac|h is tha|
|00001060| 74 20 77 65 20 6d 61 79 | 20 6e 6f 74 20 62 65 20 |t we may| not be |
|00001070| 61 62 6c 65 20 74 6f 20 | 63 6f 61 78 20 74 68 65 |able to |coax the|
|00001080| 20 73 74 75 64 65 6e 74 | 0a 25 64 61 74 61 62 61 | student|.%databa|
|00001090| 73 65 20 69 6e 74 6f 20 | 70 72 6f 64 75 63 69 6e |se into |producin|
|000010a0| 67 20 73 75 63 68 20 61 | 20 66 69 6c 65 2e 0a 25 |g such a| file..%|
|000010b0| 41 6e 6f 74 68 65 72 20 | 70 72 6f 62 6c 65 6d 20 |Another |problem |
|000010c0| 69 73 20 74 68 61 74 20 | 77 65 20 6e 65 65 64 20 |is that |we need |
|000010d0| 73 6f 6d 65 74 68 69 6e | 67 20 6d 6f 72 65 20 73 |somethin|g more s|
|000010e0| 75 62 74 6c 65 20 69 66 | 20 74 68 65 72 65 20 61 |ubtle if| there a|
|000010f0| 72 65 20 66 69 66 74 79 | 0a 25 70 61 72 61 6d 65 |re fifty|.%parame|
|00001100| 74 65 72 73 2e 20 46 6f | 72 20 65 78 61 6d 70 6c |ters. Fo|r exampl|
|00001110| 65 2c 20 77 65 20 6d 69 | 67 68 74 20 77 61 6e 74 |e, we mi|ght want|
|00001120| 20 74 6f 20 70 72 69 6e | 74 20 6f 75 74 20 74 68 | to prin|t out th|
|00001130| 65 0a 25 63 6f 6e 74 65 | 6e 74 73 20 6f 66 20 74 |e.%conte|nts of t|
|00001140| 68 65 20 73 74 75 64 65 | 6e 74 20 64 61 74 61 62 |he stude|nt datab|
|00001150| 61 73 65 20 77 69 74 68 | 20 6f 6e 65 20 70 61 67 |ase with| one pag|
|00001160| 65 20 70 65 72 20 73 74 | 75 64 65 6e 74 2c 20 62 |e per st|udent, b|
|00001170| 75 74 20 69 74 20 63 6f | 75 6c 64 20 62 65 0a 25 |ut it co|uld be.%|
|00001180| 74 68 61 74 20 74 68 65 | 72 65 20 61 72 65 20 66 |that the|re are f|
|00001190| 69 66 74 79 20 69 6e 66 | 6f 72 6d 61 74 69 6f 6e |ifty inf|ormation|
|000011a0| 20 66 69 65 6c 64 73 20 | 70 65 72 20 73 74 75 64 | fields |per stud|
|000011b0| 65 6e 74 2e 20 45 76 65 | 6e 20 77 6f 72 73 65 2c |ent. Eve|n worse,|
|000011c0| 0a 25 74 68 65 20 6e 75 | 6d 62 65 72 20 6f 66 20 |.%the nu|mber of |
|000011d0| 70 69 65 63 65 73 20 6f | 66 20 69 6e 66 6f 72 6d |pieces o|f inform|
|000011e0| 61 74 69 6f 6e 20 70 65 | 72 20 73 74 75 64 65 6e |ation pe|r studen|
|000011f0| 74 20 6d 69 67 68 74 20 | 6e 6f 74 20 62 65 20 61 |t might |not be a|
|00001200| 0a 25 63 6f 6e 73 74 61 | 6e 74 20 6e 75 6d 62 65 |.%consta|nt numbe|
|00001210| 72 2c 20 62 65 63 61 75 | 73 65 2c 20 73 61 79 2c |r, becau|se, say,|
|00001220| 20 77 65 20 61 72 65 20 | 70 72 69 6e 74 69 6e 67 | we are |printing|
|00001230| 20 6f 75 74 20 66 69 65 | 6c 64 73 20 66 72 6f 6d | out fie|lds from|
|00001240| 20 61 20 72 65 6c 61 74 | 65 64 0a 25 66 69 6c 65 | a relat|ed.%file|
|00001250| 20 69 6e 20 77 68 69 63 | 68 20 6d 61 72 6b 73 20 | in whic|h marks |
|00001260| 6f 6e 20 69 6e 64 69 76 | 69 64 75 61 6c 20 65 78 |on indiv|idual ex|
|00001270| 61 6d 69 6e 61 74 69 6f | 6e 20 70 61 70 65 72 73 |aminatio|n papers|
|00001280| 20 61 72 65 20 68 65 6c | 64 2e 0a 25 0a 25 57 65 | are hel|d..%.%We|
|00001290| 20 73 68 61 6c 6c 20 74 | 61 63 6b 6c 65 20 6f 75 | shall t|ackle ou|
|000012a0| 72 20 73 69 6d 70 6c 65 | 20 65 78 61 6d 70 6c 65 |r simple| example|
|000012b0| 20 69 6e 20 61 20 77 61 | 79 20 74 68 61 74 20 6c | in a wa|y that l|
|000012c0| 65 6e 64 73 20 69 74 73 | 65 6c 66 0a 25 74 6f 20 |ends its|elf.%to |
|000012d0| 6d 6f 72 65 20 67 65 6e | 65 72 61 6c 69 74 79 20 |more gen|erality |
|000012e0| 6c 61 74 65 72 20 6f 6e | 2c 20 61 6e 64 20 69 6e |later on|, and in|
|000012f0| 20 61 20 66 6f 72 6d 20 | 74 68 61 74 20 6d 6f 73 | a form |that mos|
|00001300| 74 20 64 61 74 61 62 61 | 73 65 20 70 72 6f 67 72 |t databa|se progr|
|00001310| 61 6d 73 0a 25 73 68 6f | 75 6c 64 20 62 65 20 63 |ams.%sho|uld be c|
|00001320| 61 70 61 62 6c 65 20 6f | 66 20 68 61 6e 64 6c 69 |apable o|f handli|
|00001330| 6e 67 2e 0a 25 0a 25 57 | 65 20 74 68 75 73 20 70 |ng..%.%W|e thus p|
|00001340| 72 65 70 61 72 65 20 61 | 20 73 75 62 73 69 64 69 |repare a| subsidi|
|00001350| 61 72 79 20 66 69 6c 65 | 20 7c 72 65 73 75 6c 74 |ary file| |result|
|00001360| 73 2e 64 61 74 7c 0a 25 | 77 69 74 68 20 72 65 63 |s.dat|.%|with rec|
|00001370| 6f 72 64 73 20 6f 66 20 | 66 69 76 65 20 66 69 65 |ords of |five fie|
|00001380| 6c 64 73 20 69 6e 20 69 | 74 2e 0a 25 45 61 63 68 |lds in i|t..%Each|
|00001390| 20 73 74 75 64 65 6e 74 | 20 69 73 20 72 65 70 72 | student| is repr|
|000013a0| 65 73 65 6e 74 65 64 20 | 62 79 20 66 69 76 65 20 |esented |by five |
|000013b0| 6c 69 6e 65 73 20 6f 66 | 20 74 68 69 73 20 66 69 |lines of| this fi|
|000013c0| 6c 65 2c 0a 25 20 20 20 | 20 5c 62 65 67 69 6e 7b |le,.% | \begin{|
|000013d0| 6d 61 63 72 6f 63 6f 64 | 65 7d 0a 25 3c 2a 72 65 |macrocod|e}.%<*re|
|000013e0| 73 75 6c 74 73 3e 0a 4d | 69 73 73 0a 49 75 73 74 |sults>.M|iss.Iust|
|000013f0| 61 0a 4d 6f 0a 33 34 20 | 57 69 6e 63 68 65 73 74 |a.Mo.34 |Winchest|
|00001400| 65 72 20 52 6f 61 64 5c | 5c 53 68 65 66 66 69 65 |er Road\|\Sheffie|
|00001410| 6c 64 5c 5c 45 6e 67 6c | 61 6e 64 0a 41 0a 4d 72 |ld\\Engl|and.A.Mr|
|00001420| 0a 41 72 74 68 75 72 0a | 4d 69 6e 69 74 0a 34 33 |.Arthur.|Minit.43|
|00001430| 20 53 68 65 66 66 69 65 | 6c 64 20 52 6f 61 64 5c | Sheffie|ld Road\|
|00001440| 5c 57 69 6e 63 68 65 73 | 74 65 72 5c 5c 45 6e 67 |\Winches|ter\\Eng|
|00001450| 6c 61 6e 64 0a 43 0a 25 | 3c 2f 72 65 73 75 6c 74 |land.C.%|</result|
|00001460| 73 3e 0a 25 20 20 20 20 | 5c 65 6e 64 7b 6d 61 63 |s>.% |\end{mac|
|00001470| 72 6f 63 6f 64 65 7d 0a | 25 61 6e 64 20 74 68 65 |rocode}.|%and the|
|00001480| 20 73 74 75 64 65 6e 74 | 20 72 65 63 6f 72 64 73 | student| records|
|00001490| 20 61 70 70 65 61 72 20 | 6f 6e 65 20 61 66 74 65 | appear |one afte|
|000014a0| 72 20 61 6e 6f 74 68 65 | 72 20 69 6e 20 74 68 69 |r anothe|r in thi|
|000014b0| 73 20 66 69 6c 65 2e 0a | 25 54 68 75 73 20 62 6f |s file..|%Thus bo|
|000014c0| 74 68 20 74 68 65 20 66 | 69 65 6c 64 20 61 6e 64 |th the f|ield and|
|000014d0| 20 72 65 63 6f 72 64 20 | 73 65 70 61 72 61 74 6f | record |separato|
|000014e0| 72 73 20 61 72 65 20 63 | 61 72 72 69 61 67 65 20 |rs are c|arriage |
|000014f0| 72 65 74 75 72 6e 73 2e | 0a 25 0a 25 5c 44 65 73 |returns.|.%.%\Des|
|00001500| 63 72 69 62 65 4d 61 63 | 72 6f 7b 5c 4d 65 72 67 |cribeMac|ro{\Merg|
|00001510| 65 7d 0a 25 5c 44 65 73 | 63 72 69 62 65 4d 61 63 |e}.%\Des|cribeMac|
|00001520| 72 6f 7b 5c 46 69 65 6c | 64 73 7d 0a 25 5c 54 65 |ro{\Fiel|ds}.%\Te|
|00001530| 58 5c 20 69 74 73 65 6c | 66 20 6e 65 65 64 73 20 |X\ itsel|f needs |
|00001540| 74 6f 20 6b 6e 6f 77 20 | 74 68 72 65 65 20 62 69 |to know |three bi|
|00001550| 74 73 20 6f 66 20 69 6e | 66 6f 72 6d 61 74 69 6f |ts of in|formatio|
|00001560| 6e 3a 0a 25 5c 62 65 67 | 69 6e 7b 65 6e 75 6d 65 |n:.%\beg|in{enume|
|00001570| 72 61 74 65 7d 0a 25 20 | 20 20 5c 69 74 65 6d 20 |rate}.% | \item |
|00001580| 74 68 65 20 6e 61 6d 65 | 20 6f 66 20 74 68 65 20 |the name| of the |
|00001590| 73 75 62 73 69 64 69 61 | 72 79 20 66 69 6c 65 2c |subsidia|ry file,|
|000015a0| 0a 25 20 20 20 5c 69 74 | 65 6d 20 74 68 65 20 66 |.% \it|em the f|
|000015b0| 69 65 6c 64 73 20 74 6f | 20 72 65 61 64 2c 20 61 |ields to| read, a|
|000015c0| 6e 64 0a 25 20 20 20 5c | 69 74 65 6d 20 74 68 65 |nd.% \|item the|
|000015d0| 20 74 65 6d 70 6c 61 74 | 65 20 6f 66 20 74 68 65 | templat|e of the|
|000015e0| 20 6c 65 74 74 65 72 2e | 0a 25 5c 65 6e 64 7b 65 | letter.|.%\end{e|
|000015f0| 6e 75 6d 65 72 61 74 65 | 7d 0a 25 57 65 20 70 61 |numerate|}.%We pa|
|00001600| 73 73 20 69 74 20 74 68 | 69 73 20 69 6e 66 6f 72 |ss it th|is infor|
|00001610| 6d 61 74 69 6f 6e 20 69 | 6e 20 74 68 65 20 66 6f |mation i|n the fo|
|00001620| 6c 6c 6f 77 69 6e 67 20 | 66 6f 72 6d 0a 25 20 20 |llowing |form.% |
|00001630| 20 20 5c 62 65 67 69 6e | 7b 6d 61 63 72 6f 63 6f | \begin|{macroco|
|00001640| 64 65 7d 0a 25 3c 2a 65 | 78 61 6d 70 3e 0a 5c 64 |de}.%<*e|xamp>.\d|
|00001650| 6f 63 75 6d 65 6e 74 63 | 6c 61 73 73 5b 31 32 70 |ocumentc|lass[12p|
|00001660| 74 5d 7b 6c 65 74 74 65 | 72 7d 0a 5c 75 73 65 70 |t]{lette|r}.\usep|
|00001670| 61 63 6b 61 67 65 7b 74 | 65 78 74 6d 65 72 67 7d |ackage{t|extmerg}|
|00001680| 0a 5c 62 65 67 69 6e 7b | 64 6f 63 75 6d 65 6e 74 |.\begin{|document|
|00001690| 7d 0a 5c 46 69 65 6c 64 | 73 7b 5c 54 69 74 6c 65 |}.\Field|s{\Title|
|000016a0| 5c 46 6f 72 65 6e 61 6d | 65 73 5c 53 75 72 6e 61 |\Forenam|es\Surna|
|000016b0| 6d 65 0a 20 20 20 5c 41 | 64 64 72 65 73 73 5c 47 |me. \A|ddress\G|
|000016c0| 72 61 64 65 7d 0a 5c 4d | 65 72 67 65 7b 72 65 73 |rade}.\M|erge{res|
|000016d0| 75 6c 74 73 2e 64 61 74 | 7d 7b 25 0a 5c 62 65 67 |ults.dat|}{%.\beg|
|000016e0| 69 6e 7b 6c 65 74 74 65 | 72 7d 7b 5c 54 69 74 6c |in{lette|r}{\Titl|
|000016f0| 65 5c 20 5c 46 6f 72 65 | 6e 61 6d 65 73 5c 0a 20 |e\ \Fore|names\. |
|00001700| 20 20 5c 53 75 72 6e 61 | 6d 65 5c 5c 5c 41 64 64 | \Surna|me\\\Add|
|00001710| 72 65 73 73 7d 0a 20 20 | 20 5c 6f 70 65 6e 69 6e |ress}. | \openin|
|00001720| 67 7b 44 65 61 72 20 5c | 54 69 74 6c 65 5c 20 5c |g{Dear \|Title\ \|
|00001730| 53 75 72 6e 61 6d 65 2c | 7d 0a 20 20 20 54 68 69 |Surname,|}. Thi|
|00001740| 73 20 6c 65 74 74 65 72 | 20 69 73 20 74 6f 20 69 |s letter| is to i|
|00001750| 6e 66 6f 72 6d 20 79 6f | 75 0a 20 20 20 74 68 61 |nform yo|u. tha|
|00001760| 74 20 79 6f 75 20 6f 62 | 74 61 69 6e 65 64 20 67 |t you ob|tained g|
|00001770| 72 61 64 65 20 5c 47 72 | 61 64 65 5c 20 69 6e 0a |rade \Gr|ade\ in.|
|00001780| 20 20 20 79 6f 75 72 20 | 72 65 63 65 6e 74 20 65 | your |recent e|
|00001790| 78 61 6d 69 6e 61 74 69 | 6f 6e 73 2e 0a 20 20 20 |xaminati|ons.. |
|000017a0| 5c 63 6c 6f 73 69 6e 67 | 7b 59 6f 75 72 73 20 66 |\closing|{Yours f|
|000017b0| 61 69 74 68 66 75 6c 6c | 79 2c 7d 0a 5c 65 6e 64 |aithfull|y,}.\end|
|000017c0| 7b 6c 65 74 74 65 72 7d | 7d 0a 5c 65 6e 64 7b 64 |{letter}|}.\end{d|
|000017d0| 6f 63 75 6d 65 6e 74 7d | 0a 25 3c 2f 65 78 61 6d |ocument}|.%</exam|
|000017e0| 70 3e 0a 25 20 20 20 20 | 5c 65 6e 64 7b 6d 61 63 |p>.% |\end{mac|
|000017f0| 72 6f 63 6f 64 65 7d 0a | 25 5c 4c 61 54 65 58 5c |rocode}.|%\LaTeX\|
|00001800| 20 73 68 6f 75 6c 64 0a | 25 6f 70 65 6e 20 74 68 | should.|%open th|
|00001810| 65 20 73 75 62 73 69 64 | 69 61 72 79 20 66 69 6c |e subsid|iary fil|
|00001820| 65 20 61 6e 64 2c 20 66 | 6f 72 20 65 61 63 68 20 |e and, f|or each |
|00001830| 73 65 74 20 6f 66 20 66 | 69 76 65 20 70 61 72 61 |set of f|ive para|
|00001840| 6d 65 74 65 72 73 2c 0a | 25 67 65 6e 65 72 61 74 |meters,.|%generat|
|00001850| 65 20 61 20 6c 65 74 74 | 65 72 20 69 6e 20 74 68 |e a lett|er in th|
|00001860| 65 20 7c 64 76 69 7c 20 | 66 69 6c 65 2e 20 57 68 |e |dvi| |file. Wh|
|00001870| 65 6e 20 69 74 20 72 65 | 61 63 68 65 73 20 74 68 |en it re|aches th|
|00001880| 65 20 65 6e 64 20 6f 66 | 0a 25 74 68 65 20 6d 65 |e end of|.%the me|
|00001890| 72 67 65 20 66 69 6c 65 | 2c 20 5c 4c 61 54 65 58 |rge file|, \LaTeX|
|000018a0| 5c 20 73 68 6f 75 6c 64 | 20 74 65 72 6d 69 6e 61 |\ should| termina|
|000018b0| 74 65 20 65 78 65 63 75 | 74 69 6f 6e 20 6f 66 20 |te execu|tion of |
|000018c0| 74 68 65 20 7c 5c 4d 65 | 72 67 65 7c 0a 25 63 6f |the |\Me|rge|.%co|
|000018d0| 6d 6d 61 6e 64 20 61 6e | 64 20 70 72 65 73 75 6d |mmand an|d presum|
|000018e0| 61 62 6c 79 20 66 69 6e | 69 73 68 20 74 68 65 20 |ably fin|ish the |
|000018f0| 64 6f 63 75 6d 65 6e 74 | 2e 0a 25 0a 25 5c 73 65 |document|..%.%\se|
|00001900| 63 74 69 6f 6e 7b 41 20 | 66 65 77 20 63 6f 6d 70 |ction{A |few comp|
|00001910| 6c 69 63 61 74 69 6f 6e | 73 7d 0a 25 0a 25 4c 6f |lication|s}.%.%Lo|
|00001920| 6f 6b 69 6e 67 20 61 74 | 20 74 68 65 20 61 62 6f |oking at| the abo|
|00001930| 76 65 20 65 78 61 6d 70 | 6c 65 20 69 6e 20 61 20 |ve examp|le in a |
|00001940| 62 69 74 20 6d 6f 72 65 | 20 67 65 6e 65 72 61 6c |bit more| general|
|00001950| 69 74 79 2c 0a 25 77 65 | 20 73 65 65 20 74 68 61 |ity,.%we| see tha|
|00001960| 74 20 77 65 20 61 72 65 | 20 72 65 61 64 69 6e 67 |t we are| reading|
|00001970| 0a 25 72 65 63 6f 72 64 | 73 20 6f 66 20 24 6e 24 |.%record|s of $n$|
|00001980| 20 66 69 65 6c 64 73 20 | 66 72 6f 6d 20 74 68 65 | fields |from the|
|00001990| 20 6d 65 72 67 65 20 66 | 69 6c 65 20 61 6e 64 20 | merge f|ile and |
|000019a0| 70 6c 61 63 69 6e 67 20 | 74 68 65 6d 20 69 6e 74 |placing |them int|
|000019b0| 6f 20 61 20 5c 54 65 58 | 5c 20 64 6f 63 75 6d 65 |o a \TeX|\ docume|
|000019c0| 6e 74 0a 25 69 6e 20 73 | 75 63 68 20 61 20 77 61 |nt.%in s|uch a wa|
|000019d0| 79 20 74 68 61 74 20 74 | 68 65 79 20 72 65 70 6c |y that t|hey repl|
|000019e0| 61 63 65 20 24 6e 24 20 | 70 72 65 61 73 73 69 67 |ace $n$ |preassig|
|000019f0| 6e 65 64 20 63 6f 6e 74 | 72 6f 6c 20 73 65 71 75 |ned cont|rol sequ|
|00001a00| 65 6e 63 65 73 2e 0a 25 | 48 6f 77 65 76 65 72 2c |ences..%|However,|
|00001a10| 20 69 74 20 6d 61 79 20 | 68 61 70 70 65 6e 20 74 | it may |happen t|
|00001a20| 68 61 74 20 74 68 65 20 | 6d 65 72 67 65 20 66 69 |hat the |merge fi|
|00001a30| 6c 65 20 69 73 20 70 72 | 65 70 61 72 65 64 20 62 |le is pr|epared b|
|00001a40| 79 20 68 75 6d 61 6e 73 | 2c 20 77 68 6f 20 6d 69 |y humans|, who mi|
|00001a50| 67 68 74 0a 25 70 6f 73 | 73 69 62 6c 79 20 68 61 |ght.%pos|sibly ha|
|00001a60| 76 65 20 69 6e 73 65 72 | 74 65 64 20 73 6f 6d 65 |ve inser|ted some|
|00001a70| 20 65 78 74 72 61 20 62 | 6c 61 6e 6b 20 6c 69 6e | extra b|lank lin|
|00001a80| 65 73 20 69 6e 74 6f 20 | 74 68 65 20 66 69 6c 65 |es into |the file|
|00001a90| 2e 20 41 67 61 69 6e 2c | 20 69 74 0a 25 63 6f 75 |. Again,| it.%cou|
|00001aa0| 6c 64 20 62 65 20 74 68 | 61 74 20 63 65 72 74 61 |ld be th|at certa|
|00001ab0| 69 6e 20 73 6f 72 74 73 | 20 6f 66 20 66 69 65 6c |in sorts| of fiel|
|00001ac0| 64 73 20 6d 69 67 68 74 | 20 62 65 20 62 6c 61 6e |ds might| be blan|
|00001ad0| 6b 2c 0a 25 77 68 65 72 | 65 61 73 20 6f 74 68 65 |k,.%wher|eas othe|
|00001ae0| 72 73 20 63 61 6e 20 6e | 65 76 65 72 20 62 65 20 |rs can n|ever be |
|00001af0| 62 6c 61 6e 6b 2e 0a 25 | 50 65 72 68 61 70 73 20 |blank..%|Perhaps |
|00001b00| 69 74 20 77 6f 75 6c 64 | 20 62 65 20 62 65 74 74 |it would| be bett|
|00001b10| 65 72 20 74 6f 20 62 75 | 69 6c 64 20 69 6e 20 73 |er to bu|ild in s|
|00001b20| 6f 6d 65 20 64 65 67 72 | 65 65 20 6f 66 20 65 72 |ome degr|ee of er|
|00001b30| 72 6f 72 20 72 65 63 6f | 76 65 72 79 2e 0a 25 0a |ror reco|very..%.|
|00001b40| 25 5c 44 65 73 63 72 69 | 62 65 4d 61 63 72 6f 7b |%\Descri|beMacro{|
|00001b50| 5c 46 69 65 6c 64 73 7d | 0a 25 57 65 20 73 68 61 |\Fields}|.%We sha|
|00001b60| 6c 6c 20 6d 61 6b 65 20 | 74 68 65 20 61 73 73 75 |ll make |the assu|
|00001b70| 6d 70 74 69 6f 6e 20 74 | 68 61 74 20 74 68 65 20 |mption t|hat the |
|00001b80| 66 69 72 73 74 20 66 69 | 65 6c 64 20 69 6e 20 61 |first fi|eld in a|
|00001b90| 6e 79 20 72 65 63 6f 72 | 64 20 69 73 20 64 65 66 |ny recor|d is def|
|00001ba0| 69 6e 69 74 65 6c 79 0a | 25 61 20 6e 6f 6e 2d 62 |initely.|%a non-b|
|00001bb0| 6c 61 6e 6b 20 6f 6e 65 | 20 61 6e 64 20 74 68 61 |lank one| and tha|
|00001bc0| 74 20 77 65 20 6b 6e 6f | 77 20 62 65 66 6f 72 65 |t we kno|w before|
|00001bd0| 68 61 6e 64 20 77 68 65 | 74 68 65 72 20 65 61 63 |hand whe|ther eac|
|00001be0| 68 0a 25 6f 66 20 74 68 | 65 20 6f 74 68 65 72 73 |h.%of th|e others|
|00001bf0| 20 6d 69 67 68 74 20 63 | 6f 6e 63 65 69 76 61 62 | might c|onceivab|
|00001c00| 6c 79 20 62 65 20 62 6c | 61 6e 6b 2e 0a 25 57 65 |ly be bl|ank..%We|
|00001c10| 20 6d 61 6b 65 20 61 20 | 6d 6f 64 69 66 69 63 61 | make a |modifica|
|00001c20| 74 69 6f 6e 20 74 6f 20 | 6f 75 72 20 7c 5c 46 69 |tion to |our |\Fi|
|00001c30| 65 6c 64 73 7c 20 73 74 | 61 74 65 6d 65 6e 74 2e |elds| st|atement.|
|00001c40| 0a 25 49 74 20 63 61 6e | 20 63 6f 6e 74 61 69 6e |.%It can| contain|
|00001c50| 20 6e 6f 74 20 6f 6e 6c | 79 0a 25 74 68 65 20 66 | not onl|y.%the f|
|00001c60| 69 65 6c 64 20 6e 61 6d | 65 20 63 6f 6e 74 72 6f |ield nam|e contro|
|00001c70| 6c 20 73 65 71 75 65 6e | 63 65 73 20 62 75 74 20 |l sequen|ces but |
|00001c80| 61 6c 73 6f 20 74 68 65 | 20 74 6f 6b 65 6e 73 20 |also the| tokens |
|00001c90| 7c 2b 7c 20 61 6e 64 7e | 7c 2d 7c 2c 0a 25 77 69 ||+| and~||-|,.%wi|
|00001ca0| 74 68 20 74 68 65 20 66 | 6f 6c 6c 6f 77 69 6e 67 |th the f|ollowing|
|00001cb0| 20 69 6e 74 65 72 70 72 | 65 74 61 74 69 6f 6e 2e | interpr|etation.|
|00001cc0| 20 41 20 7c 2b 7c 20 69 | 6e 64 69 63 61 74 65 73 | A |+| i|ndicates|
|00001cd0| 20 74 68 61 74 20 61 6c | 6c 20 66 6f 6c 6c 6f 77 | that al|l follow|
|00001ce0| 69 6e 67 0a 25 66 69 65 | 6c 64 73 20 73 68 6f 75 |ing.%fie|lds shou|
|00001cf0| 6c 64 20 62 65 20 72 65 | 2d 72 65 61 64 20 75 6e |ld be re|-read un|
|00001d00| 74 69 6c 20 61 20 6e 6f | 6e 2d 62 6c 61 6e 6b 20 |til a no|n-blank |
|00001d10| 72 65 73 75 6c 74 20 69 | 73 20 6f 62 74 61 69 6e |result i|s obtain|
|00001d20| 65 64 2e 0a 25 41 20 7c | 2d 7c 20 69 6e 64 69 63 |ed..%A ||-| indic|
|00001d30| 61 74 65 73 20 74 68 61 | 74 20 61 6e 79 20 66 6f |ates tha|t any fo|
|00001d40| 6c 6c 6f 77 69 6e 67 20 | 66 69 65 6c 64 73 20 63 |llowing |fields c|
|00001d50| 6f 75 6c 64 20 63 6f 6e | 63 65 69 76 61 62 6c 79 |ould con|ceivably|
|00001d60| 20 62 65 20 62 6c 61 6e | 6b 2c 0a 25 73 75 62 6a | be blan|k,.%subj|
|00001d70| 65 63 74 20 74 6f 20 74 | 68 65 20 72 65 73 74 72 |ect to t|he restr|
|00001d80| 69 63 74 69 6f 6e 20 74 | 68 61 74 20 74 68 65 20 |iction t|hat the |
|00001d90| 76 65 72 79 20 66 69 72 | 73 74 20 66 69 65 6c 64 |very fir|st field|
|00001da0| 20 69 73 20 61 6c 77 61 | 79 73 20 6e 6f 6e 2d 62 | is alwa|ys non-b|
|00001db0| 6c 61 6e 6b 2e 0a 25 0a | 25 54 68 75 73 20 74 68 |lank..%.|%Thus th|
|00001dc0| 65 20 63 6f 6d 6d 61 6e | 64 0a 25 5c 62 65 67 69 |e comman|d.%\begi|
|00001dd0| 6e 7b 76 65 72 62 61 74 | 69 6d 7d 0a 25 5c 46 69 |n{verbat|im}.%\Fi|
|00001de0| 65 6c 64 73 7b 5c 61 2b | 5c 62 5c 63 2d 5c 64 7d |elds{\a+|\b\c-\d}|
|00001df0| 0a 25 5c 65 6e 64 7b 76 | 65 72 62 61 74 69 6d 7d |.%\end{v|erbatim}|
|00001e00| 0a 25 77 6f 75 6c 64 20 | 69 6e 64 69 63 61 74 65 |.%would |indicate|
|00001e10| 20 74 68 61 74 20 6f 6e | 6c 79 20 7c 5c 64 7c 20 | that on|ly |\d| |
|00001e20| 69 73 20 61 6c 6c 6f 77 | 65 64 20 74 6f 20 62 65 |is allow|ed to be|
|00001e30| 20 62 6c 61 6e 6b 2c 20 | 62 65 63 61 75 73 65 20 | blank, |because |
|00001e40| 74 68 65 0a 25 7c 2b 7c | 20 74 6f 6b 65 6e 20 68 |the.%|+|| token h|
|00001e50| 61 73 20 6e 6f 20 65 66 | 66 65 63 74 2e 0a 25 49 |as no ef|fect..%I|
|00001e60| 6e 0a 25 5c 62 65 67 69 | 6e 7b 76 65 72 62 61 74 |n.%\begi|n{verbat|
|00001e70| 69 6d 7d 0a 25 5c 46 69 | 65 6c 64 73 7b 2d 5c 61 |im}.%\Fi|elds{-\a|
|00001e80| 5c 62 2b 2d 5c 63 2b 5c | 64 7d 0a 25 5c 65 6e 64 |\b+-\c+\|d}.%\end|
|00001e90| 7b 76 65 72 62 61 74 69 | 6d 7d 0a 25 74 68 65 20 |{verbati|m}.%the |
|00001ea0| 69 6e 69 74 69 61 6c 20 | 7c 2d 7c 20 74 6f 6b 65 |initial ||-| toke|
|00001eb0| 6e 20 65 6e 61 62 6c 65 | 73 20 62 6c 61 6e 6b 20 |n enable|s blank |
|00001ec0| 72 65 61 64 69 6e 67 20 | 6f 66 20 64 61 74 61 20 |reading |of data |
|00001ed0| 74 6f 6b 65 6e 73 2c 20 | 62 75 74 20 74 68 65 20 |tokens, |but the |
|00001ee0| 76 65 72 79 0a 25 66 69 | 72 73 74 20 64 61 74 61 |very.%fi|rst data|
|00001ef0| 20 74 6f 6b 65 6e 20 69 | 73 20 6e 6f 74 20 70 65 | token i|s not pe|
|00001f00| 72 6d 69 74 74 65 64 20 | 74 6f 20 62 65 20 62 6c |rmitted |to be bl|
|00001f10| 61 6e 6b 20 61 6e 79 77 | 61 79 2e 0a 25 54 68 75 |ank anyw|ay..%Thu|
|00001f20| 73 20 7c 5c 61 7c 20 69 | 73 20 72 65 61 64 20 61 |s |\a| i|s read a|
|00001f30| 73 20 61 20 6e 6f 6e 2d | 62 6c 61 6e 6b 20 74 6f |s a non-|blank to|
|00001f40| 6b 65 6e 20 61 6e 64 20 | 7c 5c 62 7c 20 61 73 20 |ken and ||\b| as |
|00001f50| 61 0a 25 70 6f 73 73 69 | 62 6c 79 20 62 6c 61 6e |a.%possi|bly blan|
|00001f60| 6b 20 74 6f 6b 65 6e 2e | 0a 25 54 68 65 20 73 65 |k token.|.%The se|
|00001f70| 71 75 65 6e 63 65 20 7c | 2b 2d 7c 20 6e 6f 77 20 |quence ||+-| now |
|00001f80| 73 77 69 74 63 68 65 73 | 20 6e 6f 6e 2d 62 6c 61 |switches| non-bla|
|00001f90| 6e 6b 20 72 65 61 64 69 | 6e 67 20 6f 6e 20 61 6e |nk readi|ng on an|
|00001fa0| 64 20 6f 66 66 20 61 67 | 61 69 6e 2c 0a 25 73 6f |d off ag|ain,.%so|
|00001fb0| 20 7c 5c 63 7c 20 69 73 | 20 72 65 61 64 20 61 73 | |\c| is| read as|
|00001fc0| 20 70 6f 73 73 69 62 6c | 79 20 62 6c 61 6e 6b 2e | possibl|y blank.|
|00001fd0| 0a 25 46 69 6e 61 6c 6c | 79 20 7c 5c 64 7c 20 69 |.%Finall|y |\d| i|
|00001fe0| 73 20 6e 6f 6e 2d 62 6c | 61 6e 6b 2e 0a 25 0a 25 |s non-bl|ank..%.%|
|00001ff0| 41 6e 6f 74 68 65 72 20 | 63 6f 6d 70 6c 69 63 61 |Another |complica|
|00002000| 74 69 6f 6e 20 77 65 20 | 61 6c 6c 6f 77 20 69 73 |tion we |allow is|
|00002010| 20 74 68 61 74 20 74 68 | 65 20 7c 5c 46 69 65 6c | that th|e |\Fiel|
|00002020| 64 73 7c 20 63 6f 6d 6d | 61 6e 64 20 63 61 6e 0a |ds| comm|and can.|
|00002030| 25 61 70 70 65 61 72 20 | 73 65 76 65 72 61 6c 20 |%appear |several |
|00002040| 74 69 6d 65 73 20 69 6e | 20 6f 75 72 20 66 69 6c |times in| our fil|
|00002050| 65 2e 20 54 68 65 20 69 | 6e 74 65 72 70 72 65 74 |e. The i|nterpret|
|00002060| 61 74 69 6f 6e 20 69 73 | 20 74 68 61 74 0a 25 74 |ation is| that.%t|
|00002070| 68 65 20 6c 61 73 74 20 | 6f 63 63 75 72 72 65 6e |he last |occurren|
|00002080| 63 65 20 6f 66 20 7c 5c | 46 69 65 6c 64 73 7c 20 |ce of |\|Fields| |
|00002090| 62 65 66 6f 72 65 20 77 | 65 20 65 6e 63 6f 75 6e |before w|e encoun|
|000020a0| 74 65 72 20 74 68 65 20 | 7c 5c 4d 65 72 67 65 7c |ter the ||\Merge||
|000020b0| 0a 25 63 6f 6d 6d 61 6e | 64 20 77 69 6c 6c 20 69 |.%comman|d will i|
|000020c0| 6e 64 69 63 61 74 65 20 | 74 68 65 20 66 69 65 6c |ndicate |the fiel|
|000020d0| 64 73 20 74 6f 20 62 65 | 20 72 65 61 64 20 66 6f |ds to be| read fo|
|000020e0| 72 20 65 76 65 72 79 20 | 72 65 63 6f 72 64 2e 20 |r every |record. |
|000020f0| 41 6e 79 0a 25 6f 63 63 | 75 72 72 65 6e 63 65 73 |Any.%occ|urrences|
|00002100| 20 6f 66 20 7c 5c 46 69 | 65 6c 64 73 7c 20 77 69 | of |\Fi|elds| wi|
|00002110| 74 68 69 6e 20 74 68 65 | 20 6d 65 72 67 65 64 20 |thin the| merged |
|00002120| 74 65 78 74 20 69 6e 64 | 69 63 61 74 65 20 61 20 |text ind|icate a |
|00002130| 6e 65 77 20 6c 69 73 74 | 0a 25 6f 66 20 66 69 65 |new list|.%of fie|
|00002140| 6c 64 73 20 74 6f 20 62 | 65 20 72 65 61 64 20 77 |lds to b|e read w|
|00002150| 68 65 6e 20 74 68 61 74 | 20 63 6f 6d 6d 61 6e 64 |hen that| command|
|00002160| 20 69 73 20 65 6e 63 6f | 75 6e 74 65 72 65 64 2e | is enco|untered.|
|00002170| 20 54 68 69 73 20 6c 65 | 74 73 20 75 73 0a 25 64 | This le|ts us.%d|
|00002180| 6f 20 73 6f 6d 65 20 63 | 6f 6e 64 69 74 69 6f 6e |o some c|ondition|
|00002190| 61 6c 20 70 72 6f 63 65 | 73 73 69 6e 67 2c 20 73 |al proce|ssing, s|
|000021a0| 75 63 68 20 61 73 5c 66 | 6f 6f 74 6e 6f 74 65 7b |uch as\f|ootnote{|
|000021b0| 49 74 20 69 73 20 61 73 | 73 75 6d 65 64 20 74 68 |It is as|sumed th|
|000021c0| 61 74 0a 25 7b 5c 74 74 | 5c 73 74 72 69 6e 67 5c |at.%{\tt|\string\|
|000021d0| 4d 72 73 7d 20 65 78 70 | 61 6e 64 73 20 74 6f 20 |Mrs} exp|ands to |
|000021e0| 7b 5c 74 74 20 4d 72 73 | 7d 2e 7d 0a 25 5c 62 65 |{\tt Mrs|}.}.%\be|
|000021f0| 67 69 6e 7b 76 65 72 62 | 61 74 69 6d 7d 0a 25 20 |gin{verb|atim}.% |
|00002200| 20 20 5c 69 66 78 5c 54 | 69 74 6c 65 5c 4d 72 73 | \ifx\T|itle\Mrs|
|00002210| 0a 25 20 20 20 20 20 20 | 5c 46 69 65 6c 64 73 7b |.% |\Fields{|
|00002220| 5c 4d 61 69 64 65 6e 4e | 61 6d 65 7d 0a 25 20 20 |\MaidenN|ame}.% |
|00002230| 20 5c 66 69 0a 25 5c 65 | 6e 64 7b 76 65 72 62 61 | \fi.%\e|nd{verba|
|00002240| 74 69 6d 7d 0a 25 61 6e | 64 20 61 6c 73 6f 20 67 |tim}.%an|d also g|
|00002250| 69 76 65 73 20 75 73 20 | 73 6f 6d 65 20 66 6c 65 |ives us |some fle|
|00002260| 78 69 62 69 6c 69 74 79 | 20 61 62 6f 75 74 20 74 |xibility| about t|
|00002270| 68 65 20 66 69 65 6c 64 | 20 6f 72 64 65 72 20 6c |he field| order l|
|00002280| 61 74 65 72 20 6f 6e 2e | 0a 25 0a 25 49 74 20 73 |ater on.|.%.%It s|
|00002290| 68 6f 75 6c 64 20 61 6c | 73 6f 20 62 65 20 73 74 |hould al|so be st|
|000022a0| 72 65 73 73 65 64 20 74 | 68 61 74 20 74 68 65 20 |ressed t|hat the |
|000022b0| 75 6e 64 65 66 69 6e 65 | 64 20 63 6f 6e 74 72 6f |undefine|d contro|
|000022c0| 6c 20 73 65 71 75 65 6e | 63 65 73 0a 25 61 70 70 |l sequen|ces.%app|
|000022d0| 65 61 72 69 6e 67 20 69 | 6e 20 74 68 65 20 74 65 |earing i|n the te|
|000022e0| 6d 70 6c 61 74 65 20 6e | 65 65 64 20 6e 6f 74 0a |mplate n|eed not.|
|000022f0| 25 63 6f 72 72 65 73 70 | 6f 6e 64 20 65 78 61 63 |%corresp|ond exac|
|00002300| 74 6c 79 20 74 6f 20 74 | 68 65 20 66 69 65 6c 64 |tly to t|he field|
|00002310| 73 20 69 6e 20 74 68 65 | 20 73 75 62 73 69 64 69 |s in the| subsidi|
|00002320| 61 72 79 20 66 69 6c 65 | 2e 0a 25 41 6e 20 65 78 |ary file|..%An ex|
|00002330| 61 6d 70 6c 65 20 6d 69 | 67 68 74 20 62 65 20 74 |ample mi|ght be t|
|00002340| 68 61 74 20 74 68 65 20 | 73 75 62 73 69 64 69 61 |hat the |subsidia|
|00002350| 72 79 20 66 69 6c 65 20 | 63 6f 6e 74 61 69 6e 73 |ry file |contains|
|00002360| 20 74 68 65 20 74 65 78 | 74 0a 25 5c 62 65 67 69 | the tex|t.%\begi|
|00002370| 6e 7b 76 65 72 62 61 74 | 69 6d 7d 0a 25 53 70 72 |n{verbat|im}.%Spr|
|00002380| 69 67 67 73 2c 20 4d 72 | 20 41 62 72 61 68 61 6d |iggs, Mr| Abraham|
|00002390| 20 4c 0a 25 5c 65 6e 64 | 7b 76 65 72 62 61 74 69 | L.%\end|{verbati|
|000023a0| 6d 7d 0a 25 61 6e 64 20 | 6f 6e 65 20 66 69 65 6c |m}.%and |one fiel|
|000023b0| 64 20 72 65 61 64 20 69 | 73 20 7c 5c 46 75 6c 6c |d read i|s |\Full|
|000023c0| 4e 61 6d 65 7c 2e 0a 25 | 5c 54 65 58 5c 20 77 6f |Name|..%|\TeX\ wo|
|000023d0| 75 6c 64 20 74 68 65 6e | 20 68 61 76 65 20 74 6f |uld then| have to|
|000023e0| 20 70 72 65 2d 70 72 6f | 63 65 73 73 20 74 68 69 | pre-pro|cess thi|
|000023f0| 73 0a 25 6e 61 6d 65 20 | 74 6f 20 67 65 6e 65 72 |s.%name |to gener|
|00002400| 61 74 65 20 69 74 73 20 | 73 65 76 65 72 61 6c 20 |ate its |several |
|00002410| 63 6f 6d 70 6f 6e 65 6e | 74 73 20 61 73 20 75 73 |componen|ts as us|
|00002420| 65 64 20 69 6e 20 74 68 | 65 20 74 65 6d 70 6c 61 |ed in th|e templa|
|00002430| 74 65 2e 0a 25 54 68 65 | 20 63 6f 6d 6d 61 6e 64 |te..%The| command|
|00002440| 20 7c 5c 50 72 65 50 72 | 6f 63 65 73 73 7c 20 63 | |\PrePr|ocess| c|
|00002450| 6f 75 6c 64 20 62 65 20 | 69 6e 63 6c 75 64 65 64 |ould be |included|
|00002460| 20 61 74 20 74 68 65 20 | 73 74 61 72 74 20 6f 66 | at the |start of|
|00002470| 20 74 68 65 20 74 65 6d | 70 6c 61 74 65 2e 0a 25 | the tem|plate..%|
|00002480| 5c 62 65 67 69 6e 7b 76 | 65 72 62 61 74 69 6d 7d |\begin{v|erbatim}|
|00002490| 0a 25 5c 64 65 66 5c 70 | 61 72 73 65 23 31 2c 20 |.%\def\p|arse#1, |
|000024a0| 23 32 20 23 33 5c 65 6e | 64 70 61 72 73 65 7b 25 |#2 #3\en|dparse{%|
|000024b0| 0a 25 20 20 20 5c 64 65 | 66 5c 53 75 72 6e 61 6d |.% \de|f\Surnam|
|000024c0| 65 7b 23 31 7d 5c 64 65 | 66 5c 54 69 74 6c 65 7b |e{#1}\de|f\Title{|
|000024d0| 23 32 7d 25 0a 25 20 20 | 20 5c 64 65 66 5c 46 6f |#2}%.% | \def\Fo|
|000024e0| 72 65 6e 61 6d 65 73 7b | 23 33 7d 7d 0a 25 5c 64 |renames{|#3}}.%\d|
|000024f0| 65 66 5c 50 72 65 50 72 | 6f 63 65 73 73 7b 5c 65 |ef\PrePr|ocess{\e|
|00002500| 78 70 61 6e 64 61 66 74 | 65 72 0a 25 20 20 20 5c |xpandaft|er.% \|
|00002510| 70 61 72 73 65 5c 46 75 | 6c 6c 4e 61 6d 65 5c 65 |parse\Fu|llName\e|
|00002520| 6e 64 70 61 72 73 65 7d | 0a 25 5c 65 6e 64 7b 76 |ndparse}|.%\end{v|
|00002530| 65 72 62 61 74 69 6d 7d | 0a 25 0a 25 41 6e 20 61 |erbatim}|.%.%An a|
|00002540| 6c 74 65 72 6e 61 74 69 | 76 65 20 61 6e 64 20 73 |lternati|ve and s|
|00002550| 69 6d 70 6c 65 72 20 6c | 6f 6f 6b 69 6e 67 20 61 |impler l|ooking a|
|00002560| 70 70 72 6f 61 63 68 20 | 74 6f 20 72 65 61 64 69 |pproach |to readi|
|00002570| 6e 67 20 66 69 65 6c 64 | 73 20 66 72 6f 6d 20 61 |ng field|s from a|
|00002580| 20 66 69 6c 65 0a 25 7c | 5c 66 69 6c 7c 20 6d 69 | file.%||\fil| mi|
|00002590| 67 68 74 20 62 65 20 74 | 6f 20 64 65 66 69 6e 65 |ght be t|o define|
|000025a0| 20 65 61 63 68 20 73 75 | 63 68 20 66 69 65 6c 64 | each su|ch field|
|000025b0| 20 61 73 0a 25 66 6f 6c | 6c 6f 77 73 2e 0a 25 5c | as.%fol|lows..%\|
|000025c0| 62 65 67 69 6e 7b 76 65 | 72 62 61 74 69 6d 7d 0a |begin{ve|rbatim}.|
|000025d0| 25 5c 64 65 66 5c 46 69 | 65 6c 64 23 31 7b 5c 64 |%\def\Fi|eld#1{\d|
|000025e0| 65 66 23 31 7b 5c 72 65 | 61 64 5c 66 69 6c 20 74 |ef#1{\re|ad\fil t|
|000025f0| 6f 23 31 23 31 7d 7d 0a | 25 5c 46 69 65 6c 64 5c |o#1#1}}.|%\Field\|
|00002600| 4e 61 6d 65 20 5c 46 69 | 65 6c 64 5c 41 64 64 72 |Name \Fi|eld\Addr|
|00002610| 65 73 73 20 5c 46 69 65 | 6c 64 5c 4d 61 72 6b 0a |ess \Fie|ld\Mark.|
|00002620| 25 5c 65 6e 64 7b 76 65 | 72 62 61 74 69 6d 7d 0a |%\end{ve|rbatim}.|
|00002630| 25 54 68 65 20 66 69 72 | 73 74 20 74 69 6d 65 20 |%The fir|st time |
|00002640| 7c 5c 4e 61 6d 65 7c 20 | 69 73 20 65 6e 63 6f 75 ||\Name| |is encou|
|00002650| 6e 74 65 72 65 64 2c 20 | 69 74 20 72 65 61 64 73 |ntered, |it reads|
|00002660| 20 69 74 73 20 6f 77 6e | 20 65 78 70 61 6e 73 69 | its own| expansi|
|00002670| 6f 6e 0a 25 66 72 6f 6d | 20 7c 5c 66 69 6c 7c 20 |on.%from| |\fil| |
|00002680| 61 6e 64 20 74 68 65 6e | 20 65 78 70 61 6e 64 73 |and then| expands|
|00002690| 20 69 74 73 65 6c 66 2e | 0a 25 48 65 6e 63 65 66 | itself.|.%Hencef|
|000026a0| 6f 72 74 68 2c 20 69 74 | 20 68 61 73 20 61 63 71 |orth, it| has acq|
|000026b0| 75 69 72 65 64 20 69 74 | 73 20 6e 65 77 20 65 78 |uired it|s new ex|
|000026c0| 70 61 6e 73 69 6f 6e 2e | 0a 25 54 68 65 20 64 69 |pansion.|.%The di|
|000026d0| 73 61 64 76 61 6e 74 61 | 67 65 20 69 73 20 74 68 |sadvanta|ge is th|
|000026e0| 61 74 20 7c 5c 4e 61 6d | 65 7c 20 6d 75 73 74 20 |at |\Nam|e| must |
|000026f0| 61 70 70 65 61 72 20 69 | 6e 20 74 68 65 0a 25 74 |appear i|n the.%t|
|00002700| 65 78 74 20 62 65 66 6f | 72 65 20 61 6e 79 20 73 |ext befo|re any s|
|00002710| 75 62 73 69 64 69 61 72 | 79 20 66 69 65 6c 64 20 |ubsidiar|y field |
|00002720| 73 75 63 68 20 61 73 20 | 7c 5c 53 75 72 6e 61 6d |such as ||\Surnam|
|00002730| 65 7c 0a 25 63 61 6e 20 | 62 65 20 75 73 65 64 2e |e|.%can |be used.|
|00002740| 0a 25 0a 25 46 69 6e 61 | 6c 6c 79 20 77 65 20 73 |.%.%Fina|lly we s|
|00002750| 68 6f 75 6c 64 20 63 6f | 6e 73 69 64 65 72 20 74 |hould co|nsider t|
|00002760| 68 65 20 70 6f 73 73 69 | 62 69 6c 69 74 79 20 74 |he possi|bility t|
|00002770| 68 61 74 20 74 68 65 20 | 73 65 63 6f 6e 64 20 70 |hat the |second p|
|00002780| 61 72 61 6d 65 74 65 72 | 20 6f 66 0a 25 7c 5c 4d |arameter| of.%|\M|
|00002790| 65 72 67 65 7c 20 6d 69 | 67 68 74 20 62 65 20 74 |erge| mi|ght be t|
|000027a0| 6f 6f 20 6c 61 72 67 65 | 20 74 6f 20 66 69 74 20 |oo large| to fit |
|000027b0| 69 6e 74 6f 20 6d 65 6d | 6f 72 79 2e 20 57 65 20 |into mem|ory. We |
|000027c0| 63 61 6e 20 63 6c 65 61 | 72 6c 79 20 68 61 6e 64 |can clea|rly hand|
|000027d0| 6c 65 0a 25 74 68 69 73 | 20 70 72 6f 62 6c 65 6d |le.%this| problem|
|000027e0| 20 62 79 20 61 6c 6c 6f | 77 69 6e 67 20 74 68 65 | by allo|wing the|
|000027f0| 20 73 65 63 6f 6e 64 20 | 70 61 72 61 6d 65 74 65 | second |paramete|
|00002800| 72 20 6d 65 72 65 6c 79 | 20 74 6f 20 63 6f 6e 73 |r merely| to cons|
|00002810| 69 73 74 20 6f 66 20 74 | 68 65 20 74 65 78 74 0a |ist of t|he text.|
|00002820| 25 7c 5c 69 6e 70 75 74 | 20 74 65 6d 70 6c 61 74 |%|\input| templat|
|00002830| 65 7c 2c 20 73 6f 20 74 | 68 61 74 20 74 68 65 20 |e|, so t|hat the |
|00002840| 72 6f 6f 74 20 66 69 6c | 65 20 68 61 6e 64 6c 65 |root fil|e handle|
|00002850| 73 20 74 77 6f 20 73 75 | 62 73 69 64 69 61 72 79 |s two su|bsidiary|
|00002860| 0a 25 66 69 6c 65 73 2c | 20 6f 6e 65 20 63 6f 6e |.%files,| one con|
|00002870| 74 61 69 6e 69 6e 67 20 | 74 68 65 20 74 65 6d 70 |taining |the temp|
|00002880| 6c 61 74 65 20 61 6e 64 | 20 74 68 65 20 6f 74 68 |late and| the oth|
|00002890| 65 72 20 63 6f 6e 74 61 | 69 6e 69 6e 67 20 74 68 |er conta|ining th|
|000028a0| 65 20 66 69 65 6c 64 73 | 2e 0a 25 0a 25 0a 25 5c |e fields|..%.%.%\|
|000028b0| 73 65 63 74 69 6f 6e 7b | 41 20 63 6f 6d 70 6c 69 |section{|A compli|
|000028c0| 63 61 74 65 64 20 65 78 | 61 6d 70 6c 65 7d 0a 25 |cated ex|ample}.%|
|000028d0| 0a 25 57 65 20 77 69 6c | 6c 20 6e 65 78 74 20 6c |.%We wil|l next l|
|000028e0| 6f 6f 6b 20 61 74 20 61 | 6e 20 65 78 61 6d 70 6c |ook at a|n exampl|
|000028f0| 65 20 69 6e 20 77 68 69 | 63 68 20 74 68 65 20 74 |e in whi|ch the t|
|00002900| 65 6d 70 6c 61 74 65 20 | 63 6f 6e 74 61 69 6e 73 |emplate |contains|
|00002910| 20 61 20 74 61 62 6c 65 | 0a 25 6f 66 20 69 6e 64 | a table|.%of ind|
|00002920| 65 74 65 72 6d 69 6e 61 | 74 65 20 6c 65 6e 67 74 |etermina|te lengt|
|00002930| 68 2c 20 61 6c 62 65 69 | 74 20 66 69 78 65 64 20 |h, albei|t fixed |
|00002940| 77 69 64 74 68 2e 20 53 | 6f 20 66 61 72 20 6f 75 |width. S|o far ou|
|00002950| 72 20 6d 61 63 72 6f 73 | 20 77 6f 72 6b 0a 25 69 |r macros| work.%i|
|00002960| 6e 20 65 69 74 68 65 72 | 20 70 6c 61 69 6e 20 5c |n either| plain \|
|00002970| 54 65 58 5c 20 6f 72 20 | 69 6e 20 5c 4c 61 54 65 |TeX\ or |in \LaTe|
|00002980| 58 2c 20 62 75 74 20 74 | 68 65 20 77 61 79 20 69 |X, but t|he way i|
|00002990| 6e 20 77 68 69 63 68 20 | 74 68 65 73 65 0a 25 74 |n which |these.%t|
|000029a0| 77 6f 20 70 61 63 6b 61 | 67 65 73 20 68 61 6e 64 |wo packa|ges hand|
|000029b0| 6c 65 0a 25 74 61 62 6c | 65 73 20 69 73 20 73 6c |le.%tabl|es is sl|
|000029c0| 69 67 68 74 6c 79 20 64 | 69 66 66 65 72 65 6e 74 |ightly d|ifferent|
|000029d0| 2e 20 48 6f 77 65 76 65 | 72 2c 20 74 68 65 20 6f |. Howeve|r, the o|
|000029e0| 6e 6c 79 20 64 69 66 66 | 65 72 65 6e 63 65 20 74 |nly diff|erence t|
|000029f0| 68 61 74 20 6e 65 65 64 | 0a 25 63 6f 6e 63 65 72 |hat need|.%concer|
|00002a00| 6e 20 75 73 20 69 73 20 | 74 68 61 74 20 5c 4c 61 |n us is |that \La|
|00002a10| 54 65 58 5c 20 75 73 65 | 73 20 7c 5c 5c 7c 20 77 |TeX\ use|s |\\| w|
|00002a20| 68 65 72 65 20 70 6c 61 | 69 6e 20 5c 54 65 58 5c |here pla|in \TeX\|
|00002a30| 20 75 73 65 73 20 7c 5c | 63 72 7c 2e 0a 25 0a 25 | uses |\|cr|..%.%|
|00002a40| 5c 44 65 73 63 72 69 62 | 65 4d 61 63 72 6f 7b 5c |\Describ|eMacro{\|
|00002a50| 4d 75 6c 74 69 52 65 61 | 64 7d 0a 25 54 68 65 20 |MultiRea|d}.%The |
|00002a60| 65 78 61 6d 70 6c 65 20 | 67 69 76 65 6e 20 68 65 |example |given he|
|00002a70| 72 65 20 69 73 20 69 6e | 20 5c 4c 61 54 65 58 2c |re is in| \LaTeX,|
|00002a80| 20 62 75 74 20 6f 75 72 | 20 73 74 79 6c 65 20 77 | but our| style w|
|00002a90| 69 6c 6c 20 77 6f 72 6b | 20 65 71 75 61 6c 6c 79 |ill work| equally|
|00002aa0| 20 77 65 6c 6c 0a 25 69 | 6e 20 70 6c 61 69 6e 20 | well.%i|n plain |
|00002ab0| 5c 54 65 58 2e 20 49 6e | 20 6f 75 72 20 73 74 75 |\TeX. In| our stu|
|00002ac0| 64 65 6e 74 20 6c 65 74 | 74 65 72 20 77 65 20 77 |dent let|ter we w|
|00002ad0| 69 73 68 20 74 6f 20 69 | 6e 73 65 72 74 20 61 20 |ish to i|nsert a |
|00002ae0| 74 61 62 6c 65 20 6f 66 | 20 63 6f 75 72 73 65 0a |table of| course.|
|00002af0| 25 63 6f 64 65 73 20 61 | 6e 64 20 6d 61 72 6b 73 |%codes a|nd marks|
|00002b00| 2e 20 53 69 6e 63 65 20 | 65 61 63 68 20 73 74 75 |. Since |each stu|
|00002b10| 64 65 6e 74 20 64 69 64 | 20 61 20 64 69 66 66 65 |dent did| a diffe|
|00002b20| 72 65 6e 74 20 6e 75 6d | 62 65 72 20 6f 66 20 63 |rent num|ber of c|
|00002b30| 6f 75 72 73 65 73 2c 20 | 77 65 0a 25 6e 65 65 64 |ourses, |we.%need|
|00002b40| 20 73 6f 6d 65 20 77 61 | 79 20 6f 66 20 72 65 63 | some wa|y of rec|
|00002b50| 6f 67 6e 69 7a 69 6e 67 | 20 74 68 65 20 65 6e 64 |ognizing| the end|
|00002b60| 20 6f 66 20 74 68 65 20 | 63 6f 75 72 73 65 20 6c | of the |course l|
|00002b70| 69 73 74 20 69 6e 20 74 | 68 65 20 6d 65 72 67 65 |ist in t|he merge|
|00002b80| 20 66 69 6c 65 2e 0a 25 | 54 68 65 20 64 65 66 61 | file..%|The defa|
|00002b90| 75 6c 74 20 77 69 6c 6c | 20 62 65 20 74 6f 20 69 |ult will| be to i|
|00002ba0| 6e 73 65 72 74 20 61 20 | 62 6c 61 6e 6b 20 6c 69 |nsert a |blank li|
|00002bb0| 6e 65 20 61 74 20 74 68 | 65 20 65 6e 64 20 6f 66 |ne at th|e end of|
|00002bc0| 20 73 75 63 68 20 61 20 | 73 75 62 2d 6c 69 73 74 | such a |sub-list|
|00002bd0| 2e 0a 25 54 68 75 73 2c | 20 74 68 65 20 66 6f 6c |..%Thus,| the fol|
|00002be0| 6c 6f 77 69 6e 67 20 74 | 65 78 74 20 61 70 70 65 |lowing t|ext appe|
|00002bf0| 61 72 73 20 62 65 66 6f | 72 65 20 74 68 65 20 63 |ars befo|re the c|
|00002c00| 6c 6f 73 65 20 6f 66 20 | 74 68 65 20 6c 65 74 74 |lose of |the lett|
|00002c10| 65 72 20 74 65 6d 70 6c | 61 74 65 2e 0a 25 5c 62 |er templ|ate..%\b|
|00002c20| 65 67 69 6e 7b 76 65 72 | 62 61 74 69 6d 7d 0a 25 |egin{ver|batim}.%|
|00002c30| 48 65 72 65 20 61 72 65 | 20 79 6f 75 72 20 6d 61 |Here are| your ma|
|00002c40| 72 6b 73 20 6f 6e 20 69 | 6e 64 69 76 69 64 75 61 |rks on i|ndividua|
|00002c50| 6c 20 70 61 70 65 72 73 | 2e 0a 25 5c 62 65 67 69 |l papers|..%\begi|
|00002c60| 6e 7b 63 65 6e 74 65 72 | 7d 0a 25 20 20 20 5c 62 |n{center|}.% \b|
|00002c70| 65 67 69 6e 7b 74 61 62 | 75 6c 61 72 7d 7b 7c 6c |egin{tab|ular}{|l|
|00002c80| 72 7c 7d 5c 68 6c 69 6e | 65 0a 25 20 20 20 20 20 |r|}\hlin|e.% |
|00002c90| 20 43 6f 64 65 26 4d 61 | 72 6b 5c 5c 5c 68 6c 69 | Code&Ma|rk\\\hli|
|00002ca0| 6e 65 0a 25 20 20 20 20 | 20 20 5c 4d 75 6c 74 69 |ne.% | \Multi|
|00002cb0| 52 65 61 64 7b 32 7d 5c | 5c 5c 68 6c 69 6e 65 0a |Read{2}\|\\hline.|
|00002cc0| 25 20 20 20 5c 65 6e 64 | 7b 74 61 62 75 6c 61 72 |% \end|{tabular|
|00002cd0| 7d 0a 25 5c 65 6e 64 7b | 63 65 6e 74 65 72 7d 0a |}.%\end{|center}.|
|00002ce0| 25 5c 65 6e 64 7b 76 65 | 72 62 61 74 69 6d 7d 0a |%\end{ve|rbatim}.|
|00002cf0| 25 54 68 65 20 6d 65 72 | 67 65 20 66 69 6c 65 20 |%The mer|ge file |
|00002d00| 6e 6f 77 20 68 61 73 20 | 74 68 65 20 66 6f 6c 6c |now has |the foll|
|00002d10| 6f 77 69 6e 67 20 73 74 | 72 75 63 74 75 72 65 2e |owing st|ructure.|
|00002d20| 0a 25 5c 62 65 67 69 6e | 7b 76 65 72 62 61 74 69 |.%\begin|{verbati|
|00002d30| 6d 7d 0a 25 54 69 74 6c | 65 0a 25 2e 2e 2e 0a 25 |m}.%Titl|e.%....%|
|00002d40| 47 72 61 64 65 0a 25 43 | 6f 64 65 0a 25 4d 61 72 |Grade.%C|ode.%Mar|
|00002d50| 6b 0a 25 2e 2e 2e 0a 25 | 43 6f 64 65 0a 25 4d 61 |k.%....%|Code.%Ma|
|00002d60| 72 6b 0a 25 5c 65 6e 64 | 7b 76 65 72 62 61 74 69 |rk.%\end|{verbati|
|00002d70| 6d 7d 0a 25 24 5c 6c 61 | 6e 67 6c 65 24 7b 5c 69 |m}.%$\la|ngle${\i|
|00002d80| 74 20 62 6c 61 6e 6b 5c | 2f 7d 24 5c 72 61 6e 67 |t blank\|/}$\rang|
|00002d90| 6c 65 24 0a 25 5c 62 65 | 67 69 6e 7b 76 65 72 62 |le$.%\be|gin{verb|
|00002da0| 61 74 69 6d 7d 0a 25 54 | 69 74 6c 65 0a 25 2e 2e |atim}.%T|itle.%..|
|00002db0| 2e 0a 25 5c 65 6e 64 7b | 76 65 72 62 61 74 69 6d |..%\end{|verbatim|
|00002dc0| 7d 0a 25 0a 25 5c 44 65 | 73 63 72 69 62 65 4d 61 |}.%.%\De|scribeMa|
|00002dd0| 63 72 6f 7b 5c 4d 61 72 | 6b 45 6e 64 7d 0a 25 49 |cro{\Mar|kEnd}.%I|
|00002de0| 6e 20 6f 74 68 65 72 20 | 61 70 70 6c 69 63 61 74 |n other |applicat|
|00002df0| 69 6f 6e 73 20 73 6f 6d | 65 20 6f 66 20 74 68 65 |ions som|e of the|
|00002e00| 20 66 69 65 6c 64 73 20 | 69 6e 20 74 68 65 20 74 | fields |in the t|
|00002e10| 61 62 6c 65 20 6d 69 67 | 68 74 20 70 6f 73 73 69 |able mig|ht possi|
|00002e20| 62 6c 79 20 62 65 20 62 | 6c 61 6e 6b 2e 0a 25 57 |bly be b|lank..%W|
|00002e30| 65 20 74 68 65 6e 20 6c | 65 74 20 74 68 65 20 75 |e then l|et the u|
|00002e40| 73 65 72 20 63 68 61 6e | 67 65 20 74 68 65 20 24 |ser chan|ge the $|
|00002e50| 5c 6c 61 6e 67 6c 65 24 | 7b 5c 69 74 20 62 6c 61 |\langle$|{\it bla|
|00002e60| 6e 6b 5c 2f 7d 24 5c 72 | 61 6e 67 6c 65 24 0a 25 |nk\/}$\r|angle$.%|
|00002e70| 6c 69 6e 65 20 6d 61 72 | 6b 69 6e 67 20 74 68 65 |line mar|king the|
|00002e80| 20 65 6e 64 20 6f 66 20 | 61 20 6c 69 73 74 20 74 | end of |a list t|
|00002e90| 6f 20 73 6f 6d 65 20 6f | 74 68 65 72 20 73 74 72 |o some o|ther str|
|00002ea0| 69 6e 67 20 6f 66 20 68 | 69 73 20 6f 77 6e 20 63 |ing of h|is own c|
|00002eb0| 68 6f 6f 73 69 6e 67 2e | 0a 25 5c 62 65 67 69 6e |hoosing.|.%\begin|
|00002ec0| 7b 76 65 72 62 61 74 69 | 6d 7d 0a 25 5c 4d 61 72 |{verbati|m}.%\Mar|
|00002ed0| 6b 45 6e 64 7b 2a 2a 2a | 7d 0a 25 5c 65 6e 64 7b |kEnd{***|}.%\end{|
|00002ee0| 76 65 72 62 61 74 69 6d | 7d 0a 25 0a 25 54 68 65 |verbatim|}.%.%The|
|00002ef0| 72 65 20 6d 69 67 68 74 | 20 62 65 20 6d 75 6c 74 |re might| be mult|
|00002f00| 69 70 6c 65 20 74 61 62 | 6c 65 73 20 69 6e 20 74 |iple tab|les in t|
|00002f10| 68 65 20 73 61 6d 65 20 | 74 65 6d 70 6c 61 74 65 |he same |template|
|00002f20| 2c 0a 25 77 69 74 68 20 | 74 68 65 69 72 20 64 61 |,.%with |their da|
|00002f30| 74 61 20 69 6e 74 65 72 | 6d 69 6e 67 6c 65 64 20 |ta inter|mingled |
|00002f40| 69 6e 20 74 68 65 20 6d | 65 72 67 65 20 66 69 6c |in the m|erge fil|
|00002f50| 65 20 77 69 74 68 20 6d | 61 69 6e 20 66 69 65 6c |e with m|ain fiel|
|00002f60| 64 73 2e 0a 25 54 68 65 | 20 67 65 6e 65 72 61 6c |ds..%The| general|
|00002f70| 69 7a 65 64 20 7c 5c 46 | 69 65 6c 64 73 7c 20 63 |ized |\F|ields| c|
|00002f80| 6f 6d 6d 61 6e 64 20 61 | 6c 6c 6f 77 73 20 75 73 |ommand a|llows us|
|00002f90| 0a 25 74 6f 20 6f 72 64 | 65 72 20 74 68 65 20 6d |.%to ord|er the m|
|00002fa0| 65 72 67 65 20 66 69 6c | 65 20 68 6f 77 65 76 65 |erge fil|e howeve|
|00002fb0| 72 20 77 65 20 77 61 6e | 74 2e 20 54 68 75 73 20 |r we wan|t. Thus |
|00002fc0| 77 65 20 63 6f 75 6c 64 | 20 68 61 76 65 20 6d 61 |we could| have ma|
|00002fd0| 69 6e 20 66 69 65 6c 64 | 73 2c 20 74 68 65 6e 0a |in field|s, then.|
|00002fe0| 25 61 20 74 61 62 6c 65 | 2c 20 66 6f 6c 6c 6f 77 |%a table|, follow|
|00002ff0| 65 64 20 62 79 20 6d 6f | 72 65 20 6d 61 69 6e 20 |ed by mo|re main |
|00003000| 66 69 65 6c 64 73 2c 20 | 61 6e 64 20 73 6f 20 6f |fields, |and so o|
|00003010| 6e 2e 0a 25 0a 25 5c 44 | 65 73 63 72 69 62 65 4d |n..%.%\D|escribeM|
|00003020| 61 63 72 6f 7b 5c 50 72 | 6f 63 65 73 73 7d 0a 25 |acro{\Pr|ocess}.%|
|00003030| 41 20 66 69 6e 61 6c 20 | 63 6f 6d 70 6c 69 63 61 |A final |complica|
|00003040| 74 69 6f 6e 20 69 73 20 | 74 68 61 74 20 74 68 65 |tion is |that the|
|00003050| 20 66 69 65 6c 64 73 20 | 61 70 70 65 61 72 69 6e | fields |appearin|
|00003060| 67 20 69 6e 20 61 20 74 | 61 62 6c 65 20 61 72 65 |g in a t|able are|
|00003070| 20 65 73 73 65 6e 74 69 | 61 6c 6c 79 0a 25 61 6e | essenti|ally.%an|
|00003080| 6f 6e 79 6d 6f 75 73 2e | 20 42 79 20 74 68 69 73 |onymous.| By this|
|00003090| 20 49 20 6d 65 61 6e 20 | 74 68 61 74 20 74 68 65 | I mean |that the|
|000030a0| 79 20 61 72 65 20 74 72 | 61 6e 73 66 65 72 72 65 |y are tr|ansferre|
|000030b0| 64 20 69 6e 74 6f 20 74 | 68 65 20 74 61 62 6c 65 |d into t|he table|
|000030c0| 20 61 73 0a 25 74 68 65 | 79 20 61 72 65 2c 20 77 | as.%the|y are, w|
|000030d0| 69 74 68 6f 75 74 20 61 | 6e 79 20 70 72 65 2d 70 |ithout a|ny pre-p|
|000030e0| 72 6f 63 65 73 73 69 6e | 67 20 70 6f 73 73 69 62 |rocessin|g possib|
|000030f0| 6c 65 20 74 68 72 6f 75 | 67 68 20 61 70 70 65 61 |le throu|gh appea|
|00003100| 72 69 6e 67 0a 25 69 6e | 20 74 68 65 20 74 65 6d |ring.%in| the tem|
|00003110| 70 6c 61 74 65 20 61 73 | 20 63 6f 6e 74 72 6f 6c |plate as| control|
|00003120| 20 73 65 71 75 65 6e 63 | 65 73 2e 20 49 66 20 77 | sequenc|es. If w|
|00003130| 65 20 77 69 73 68 20 77 | 68 61 74 20 61 70 70 65 |e wish w|hat appe|
|00003140| 61 72 73 20 69 6e 0a 25 | 74 68 65 20 74 61 62 6c |ars in.%|the tabl|
|00003150| 65 20 74 6f 20 62 65 20 | 64 69 66 66 65 72 65 6e |e to be |differen|
|00003160| 74 20 66 72 6f 6d 20 77 | 68 61 74 20 61 70 70 65 |t from w|hat appe|
|00003170| 61 72 73 20 69 6e 20 74 | 68 65 20 66 69 6c 65 2c |ars in t|he file,|
|00003180| 20 61 20 6d 65 63 68 61 | 6e 69 73 6d 20 69 73 20 | a mecha|nism is |
|00003190| 6e 65 65 64 65 64 0a 25 | 74 6f 20 74 65 6c 6c 20 |needed.%|to tell |
|000031a0| 5c 54 65 58 5c 20 74 68 | 61 74 20 61 20 63 65 72 |\TeX\ th|at a cer|
|000031b0| 74 61 69 6e 20 63 6f 6c | 75 6d 6e 20 68 61 73 20 |tain col|umn has |
|000031c0| 74 6f 20 62 65 20 74 72 | 65 61 74 65 64 20 69 6e |to be tr|eated in|
|000031d0| 20 61 20 63 65 72 74 61 | 69 6e 20 77 61 79 2e 0a | a certa|in way..|
|000031e0| 25 54 68 65 20 63 6f 6d | 6d 61 6e 64 0a 25 5c 62 |%The com|mand.%\b|
|000031f0| 65 67 69 6e 7b 76 65 72 | 62 61 74 69 6d 7d 0a 25 |egin{ver|batim}.%|
|00003200| 5c 50 72 6f 63 65 73 73 | 7b 6e 7d 7b 5c 66 6f 6f |\Process|{n}{\foo|
|00003210| 7d 0a 25 5c 65 6e 64 7b | 76 65 72 62 61 74 69 6d |}.%\end{|verbatim|
|00003220| 7d 0a 25 77 69 6c 6c 20 | 72 65 70 6c 61 63 65 20 |}.%will |replace |
|00003230| 65 76 65 72 79 20 66 69 | 65 6c 64 20 24 5c 6c 61 |every fi|eld $\la|
|00003240| 6e 67 6c 65 20 66 5c 72 | 61 6e 67 6c 65 24 20 72 |ngle f\r|angle$ r|
|00003250| 65 61 64 20 69 6e 74 6f | 20 63 6f 6c 75 6d 6e 20 |ead into| column |
|00003260| 24 6e 24 0a 25 62 79 20 | 7c 5c 66 6f 6f 7b 7c 24 |$n$.%by ||\foo{|$|
|00003270| 5c 6c 61 6e 67 6c 65 20 | 66 5c 72 61 6e 67 6c 65 |\langle |f\rangle|
|00003280| 24 7c 7d 7c 2e 0a 25 49 | 74 20 69 73 20 65 76 65 |$|}|..%I|t is eve|
|00003290| 6e 20 70 6f 73 73 69 62 | 6c 65 20 74 6f 20 64 6f |n possib|le to do|
|000032a0| 20 73 6f 6d 65 20 6e 75 | 6d 65 72 69 63 61 6c 20 | some nu|merical |
|000032b0| 63 61 6c 63 75 6c 61 74 | 69 6f 6e 73 20 62 79 20 |calculat|ions by |
|000032c0| 74 68 69 73 20 6d 65 74 | 68 6f 64 2e 0a 25 0a 25 |this met|hod..%.%|
|000032d0| 48 65 72 65 20 69 73 20 | 61 20 5c 4c 61 54 65 58 |Here is |a \LaTeX|
|000032e0| 5c 20 65 78 61 6d 70 6c | 65 20 74 6f 20 69 6c 6c |\ exampl|e to ill|
|000032f0| 75 73 74 72 61 74 65 20 | 74 68 65 20 74 61 62 6c |ustrate |the tabl|
|00003300| 65 20 70 72 6f 63 65 73 | 73 69 6e 67 0a 25 66 65 |e proces|sing.%fe|
|00003310| 61 74 75 72 65 73 20 6f | 66 20 7c 74 65 78 74 6d |atures o|f |textm|
|00003320| 65 72 67 2e 73 74 79 7c | 2e 0a 25 20 20 20 20 5c |erg.sty||..% \|
|00003330| 62 65 67 69 6e 7b 6d 61 | 63 72 6f 63 6f 64 65 7d |begin{ma|crocode}|
|00003340| 0a 25 3c 2a 65 78 61 6d | 70 6c 65 3e 0a 5c 64 6f |.%<*exam|ple>.\do|
|00003350| 63 75 6d 65 6e 74 63 6c | 61 73 73 5b 31 32 70 74 |cumentcl|ass[12pt|
|00003360| 5d 7b 61 72 74 69 63 6c | 65 7d 0a 5c 75 73 65 70 |]{articl|e}.\usep|
|00003370| 61 63 6b 61 67 65 7b 74 | 65 78 74 6d 65 72 67 7d |ackage{t|extmerg}|
|00003380| 0a 5c 4d 61 72 6b 45 6e | 64 7b 2a 2a 2a 7d 0a 5c |.\MarkEn|d{***}.\|
|00003390| 50 72 6f 63 65 73 73 7b | 32 7d 7b 5c 41 64 76 61 |Process{|2}{\Adva|
|000033a0| 6e 63 65 7d 0a 5c 64 65 | 66 5c 41 64 76 61 6e 63 |nce}.\de|f\Advanc|
|000033b0| 65 23 31 7b 23 31 5c 61 | 64 64 74 6f 63 6f 75 6e |e#1{#1\a|ddtocoun|
|000033c0| 74 65 72 7b 70 61 67 65 | 7d 7b 23 31 7d 7d 0a 5c |ter{page|}{#1}}.\|
|000033d0| 46 69 65 6c 64 73 7b 2b | 5c 4e 61 6d 65 5c 56 65 |Fields{+|\Name\Ve|
|000033e0| 72 62 7d 0a 5c 62 65 67 | 69 6e 7b 64 6f 63 75 6d |rb}.\beg|in{docum|
|000033f0| 65 6e 74 7d 0a 5c 4d 65 | 72 67 65 7b 73 69 6c 6c |ent}.\Me|rge{sill|
|00003400| 79 2e 64 61 74 7d 7b 25 | 0a 20 20 20 44 65 61 72 |y.dat}{%|. Dear|
|00003410| 20 5c 4e 61 6d 65 2c 5c | 70 61 72 0a 20 20 20 48 | \Name,\|par. H|
|00003420| 65 72 65 20 69 73 20 61 | 20 74 61 62 6c 65 20 74 |ere is a| table t|
|00003430| 6f 20 5c 56 65 72 62 5c | 20 61 74 3a 0a 20 20 20 |o \Verb\| at:. |
|00003440| 5c 46 69 65 6c 64 73 7b | 5c 57 69 64 74 68 7d 25 |\Fields{|\Width}%|
|00003450| 0a 20 20 20 5c 62 65 67 | 69 6e 7b 74 61 62 75 6c |. \beg|in{tabul|
|00003460| 61 72 7d 7b 2a 7b 5c 57 | 69 64 74 68 7d 63 7d 0a |ar}{*{\W|idth}c}.|
|00003470| 20 20 20 20 20 20 5c 4d | 75 6c 74 69 52 65 61 64 | \M|ultiRead|
|00003480| 5c 57 69 64 74 68 0a 20 | 20 20 5c 65 6e 64 7b 74 |\Width. | \end{t|
|00003490| 61 62 75 6c 61 72 7d 2e | 5c 70 61 72 0a 20 20 20 |abular}.|\par. |
|000034a0| 5c 46 69 65 6c 64 73 7b | 5c 41 64 6a 7d 25 0a 20 |\Fields{|\Adj}%. |
|000034b0| 20 20 54 68 61 74 20 77 | 61 73 20 5c 41 64 6a 21 | That w|as \Adj!|
|000034c0| 0a 20 20 20 5c 63 6c 65 | 61 72 70 61 67 65 7d 0a |. \cle|arpage}.|
|000034d0| 5c 65 6e 64 7b 64 6f 63 | 75 6d 65 6e 74 7d 0a 25 |\end{doc|ument}.%|
|000034e0| 3c 2f 65 78 61 6d 70 6c | 65 3e 0a 25 20 20 20 20 |</exampl|e>.% |
|000034f0| 5c 65 6e 64 7b 6d 61 63 | 72 6f 63 6f 64 65 7d 0a |\end{mac|rocode}.|
|00003500| 25 54 68 65 20 65 66 66 | 65 63 74 20 6f 66 20 74 |%The eff|ect of t|
|00003510| 68 69 73 20 66 69 6c 65 | 20 69 73 20 6e 6f 74 20 |his file| is not |
|00003520| 61 70 70 61 72 65 6e 74 | 20 75 6e 74 69 6c 20 77 |apparent| until w|
|00003530| 65 20 73 65 65 20 7c 73 | 69 6c 6c 79 2e 64 61 74 |e see |s|illy.dat|
|00003540| 7c 2e 0a 25 49 74 20 69 | 73 20 6c 69 73 74 65 64 ||..%It i|s listed|
|00003550| 20 68 65 72 65 2e 0a 25 | 20 20 20 20 5c 62 65 67 | here..%| \beg|
|00003560| 69 6e 7b 6d 61 63 72 6f | 63 6f 64 65 7d 0a 25 3c |in{macro|code}.%<|
|00003570| 2a 73 69 6c 6c 79 3e 0a | 4d 69 6b 65 0a 6c 6f 6f |*silly>.|Mike.loo|
|00003580| 6b 0a 33 0a 31 0a 32 0a | 33 0a 31 31 0a 31 32 0a |k.3.1.2.|3.11.12.|
|00003590| 31 33 0a 2a 2a 2a 0a 67 | 6f 6f 64 0a 53 68 65 6c |13.***.g|ood.Shel|
|000035a0| 61 67 68 0a 67 61 7a 65 | 0a 32 0a 32 31 0a 32 32 |agh.gaze|.2.21.22|
|000035b0| 0a 32 33 0a 32 34 0a 2a | 2a 2a 0a 68 6f 72 72 69 |.23.24.*|**.horri|
|000035c0| 64 0a 25 3c 2f 73 69 6c | 6c 79 3e 0a 25 20 20 20 |d.%</sil|ly>.% |
|000035d0| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 63 6f 64 65 7d | \end{ma|crocode}|
|000035e0| 0a 25 0a 25 20 20 20 20 | 54 68 65 20 73 61 6d 65 |.%.% |The same|
|000035f0| 20 63 61 6e 20 62 65 20 | 64 6f 6e 65 20 69 6e 20 | can be |done in |
|00003600| 70 6c 61 69 6e 20 5c 54 | 65 58 2e 0a 25 20 20 20 |plain \T|eX..% |
|00003610| 20 5c 62 65 67 69 6e 7b | 6d 61 63 72 6f 63 6f 64 | \begin{|macrocod|
|00003620| 65 7d 0a 25 3c 2a 70 6c | 61 69 6e 65 78 61 6d 70 |e}.%<*pl|ainexamp|
|00003630| 6c 65 3e 0a 5c 69 6e 70 | 75 74 20 74 65 78 74 6d |le>.\inp|ut textm|
|00003640| 65 72 67 0a 5c 4d 61 72 | 6b 45 6e 64 7b 2a 2a 2a |erg.\Mar|kEnd{***|
|00003650| 7d 0a 5c 50 72 6f 63 65 | 73 73 7b 32 7d 7b 5c 41 |}.\Proce|ss{2}{\A|
|00003660| 64 76 61 6e 63 65 7d 0a | 5c 64 65 66 5c 41 64 76 |dvance}.|\def\Adv|
|00003670| 61 6e 63 65 23 31 7b 23 | 31 5c 67 6c 6f 62 61 6c |ance#1{#|1\global|
|00003680| 5c 61 64 76 61 6e 63 65 | 5c 63 6f 75 6e 74 30 62 |\advance|\count0b|
|00003690| 79 23 31 7d 0a 5c 46 69 | 65 6c 64 73 7b 2b 5c 4e |y#1}.\Fi|elds{+\N|
|000036a0| 61 6d 65 5c 56 65 72 62 | 7d 0a 5c 4d 65 72 67 65 |ame\Verb|}.\Merge|
|000036b0| 7b 73 69 6c 6c 79 2e 64 | 61 74 7d 7b 25 0a 20 20 |{silly.d|at}{%. |
|000036c0| 20 44 65 61 72 20 5c 4e | 61 6d 65 2c 5c 70 61 72 | Dear \N|ame,\par|
|000036d0| 0a 20 20 20 48 65 72 65 | 20 69 73 20 61 20 74 61 |. Here| is a ta|
|000036e0| 62 6c 65 20 74 6f 20 5c | 56 65 72 62 5c 20 61 74 |ble to \|Verb\ at|
|000036f0| 3a 0a 20 20 20 5c 46 69 | 65 6c 64 73 7b 5c 57 69 |:. \Fi|elds{\Wi|
|00003700| 64 74 68 7d 25 0a 20 20 | 20 5c 76 62 6f 78 7b 5c |dth}%. | \vbox{\|
|00003710| 68 61 6c 69 67 6e 7b 5c | 68 66 69 6c 7b 7d 20 23 |halign{\|hfil{} #|
|00003720| 23 20 7b 7d 5c 68 66 69 | 6c 26 26 5c 68 66 69 6c |# {}\hfi|l&&\hfil|
|00003730| 7b 7d 20 23 23 20 7b 7d | 5c 68 66 69 6c 5c 63 72 |{} ## {}|\hfil\cr|
|00003740| 0a 20 20 20 20 20 20 5c | 4d 75 6c 74 69 52 65 61 |. \|MultiRea|
|00003750| 64 5c 57 69 64 74 68 5c | 63 72 0a 20 20 20 7d 7d |d\Width\|cr. }}|
|00003760| 2e 5c 70 61 72 0a 20 20 | 20 5c 46 69 65 6c 64 73 |.\par. | \Fields|
|00003770| 7b 5c 41 64 6a 7d 25 0a | 20 20 20 54 68 61 74 20 |{\Adj}%.| That |
|00003780| 77 61 73 20 5c 41 64 6a | 21 0a 20 20 20 5c 76 66 |was \Adj|!. \vf|
|00003790| 69 6c 6c 5c 65 6a 65 63 | 74 7d 0a 5c 65 6e 64 0a |ill\ejec|t}.\end.|
|000037a0| 0a 25 3c 2f 70 6c 61 69 | 6e 65 78 61 6d 70 6c 65 |.%</plai|nexample|
|000037b0| 3e 0a 25 20 20 20 20 5c | 65 6e 64 7b 6d 61 63 72 |>.% \|end{macr|
|000037c0| 6f 63 6f 64 65 7d 0a 25 | 0a 25 0a 25 5c 53 74 6f |ocode}.%|.%.%\Sto|
|000037d0| 70 45 76 65 6e 74 75 61 | 6c 6c 79 7b 0a 25 5c 62 |pEventua|lly{.%\b|
|000037e0| 65 67 69 6e 7b 74 68 65 | 62 69 62 6c 69 6f 67 72 |egin{the|bibliogr|
|000037f0| 61 70 68 79 7d 7b 47 48 | 57 57 38 34 7d 0a 25 5c |aphy}{GH|WW84}.%\|
|00003800| 62 69 62 69 74 65 6d 5b | 7b 42 65 6c 7d 38 37 5d |bibitem[|{Bel}87]|
|00003810| 7b 42 65 6c 6c 3a 54 42 | 38 2d 31 2d 35 34 7d 0a |{Bell:TB|8-1-54}.|
|00003820| 25 45 64 77 69 6e 7e 56 | 2e 20 7b 42 65 6c 6c 2c |%Edwin~V|. {Bell,|
|00003830| 20 49 49 7d 2e 0a 25 5c | 6e 65 77 62 6c 6f 63 6b | II}..%\|newblock|
|00003840| 20 7b 7b 41 75 74 6f 4c | 65 74 74 65 72 3a 20 41 | {{AutoL|etter: A|
|00003850| 20 5c 54 65 58 5c 20 66 | 6f 72 6d 20 6c 65 74 74 | \TeX\ f|orm lett|
|00003860| 65 72 20 70 72 6f 63 65 | 64 75 72 65 7d 7d 2e 0a |er proce|dure}}..|
|00003870| 25 5c 6e 65 77 62 6c 6f | 63 6b 20 7b 5c 65 6d 20 |%\newblo|ck {\em |
|00003880| 54 55 47 42 6f 61 74 7d | 2c 20 38 28 31 29 3a 35 |TUGBoat}|, 8(1):5|
|00003890| 34 2c 20 41 70 72 69 6c | 20 31 39 38 37 2e 0a 25 |4, April| 1987..%|
|000038a0| 0a 25 5c 62 69 62 69 74 | 65 6d 5b 47 61 72 38 37 |.%\bibit|em[Gar87|
|000038b0| 5d 7b 47 61 72 61 76 65 | 6c 6c 69 3a 54 42 38 2d |]{Garave|lli:TB8-|
|000038c0| 31 2d 35 33 7d 0a 25 4a | 6f 68 6e 7e 53 2e 20 47 |1-53}.%J|ohn~S. G|
|000038d0| 61 72 61 76 65 6c 6c 69 | 2e 0a 25 5c 6e 65 77 62 |aravelli|..%\newb|
|000038e0| 6c 6f 63 6b 20 7b 7b 46 | 6f 72 6d 20 6c 65 74 74 |lock {{F|orm lett|
|000038f0| 65 72 20 6d 61 63 72 6f | 73 7d 7d 2e 0a 25 5c 6e |er macro|s}}..%\n|
|00003900| 65 77 62 6c 6f 63 6b 20 | 7b 5c 65 6d 20 54 55 47 |ewblock |{\em TUG|
|00003910| 42 6f 61 74 7d 2c 20 38 | 28 31 29 3a 35 33 2c 20 |Boat}, 8|(1):53, |
|00003920| 41 70 72 69 6c 20 31 39 | 38 37 2e 0a 25 0a 25 5c |April 19|87..%.%\|
|00003930| 62 69 62 69 74 65 6d 5b | 4c 65 65 38 36 5d 7b 4c |bibitem[|Lee86]{L|
|00003940| 65 65 3a 54 42 37 2d 33 | 2d 31 38 37 7d 0a 25 4a |ee:TB7-3|-187}.%J|
|00003950| 6f 68 6e 20 4c 65 65 2e | 0a 25 5c 6e 65 77 62 6c |ohn Lee.|.%\newbl|
|00003960| 6f 63 6b 20 7b 7b 46 6f | 72 6d 20 6c 65 74 74 65 |ock {{Fo|rm lette|
|00003970| 72 73 7d 7d 2e 0a 25 5c | 6e 65 77 62 6c 6f 63 6b |rs}}..%\|newblock|
|00003980| 20 7b 5c 65 6d 20 54 55 | 47 42 6f 61 74 7d 2c 20 | {\em TU|GBoat}, |
|00003990| 37 28 33 29 3a 31 38 37 | 2c 20 4f 63 74 6f 62 65 |7(3):187|, Octobe|
|000039a0| 72 20 31 39 38 36 2e 0a | 25 0a 25 5c 62 69 62 69 |r 1986..|%.%\bibi|
|000039b0| 74 65 6d 5b 4d 63 4b 38 | 37 5d 7b 4d 63 4b 69 6e |tem[McK8|7]{McKin|
|000039c0| 73 74 72 79 3a 54 42 38 | 2d 31 2d 36 30 7d 0a 25 |stry:TB8|-1-60}.%|
|000039d0| 47 72 61 65 6d 65 20 4d | 63 4b 69 6e 73 74 72 79 |Graeme M|cKinstry|
|000039e0| 2e 0a 25 5c 6e 65 77 62 | 6c 6f 63 6b 20 7b 7b 46 |..%\newb|lock {{F|
|000039f0| 6f 72 6d 20 6c 65 74 74 | 65 72 73 7d 7d 2e 0a 25 |orm lett|ers}}..%|
|00003a00| 5c 6e 65 77 62 6c 6f 63 | 6b 20 7b 5c 65 6d 20 54 |\newbloc|k {\em T|
|00003a10| 55 47 42 6f 61 74 7d 2c | 20 38 28 31 29 3a 36 30 |UGBoat},| 8(1):60|
|00003a20| 2c 20 41 70 72 69 6c 20 | 31 39 38 37 2e 0a 25 5c |, April |1987..%\|
|00003a30| 65 6e 64 7b 74 68 65 62 | 69 62 6c 69 6f 67 72 61 |end{theb|ibliogra|
|00003a40| 70 68 79 7d 0a 25 7d 0a | 25 0a 25 20 20 20 20 5c |phy}.%}.|%.% \|
|00003a50| 73 65 63 74 69 6f 6e 7b | 49 64 65 6e 74 69 66 69 |section{|Identifi|
|00003a60| 63 61 74 69 6f 6e 7d 0a | 25 0a 25 20 20 20 20 54 |cation}.|%.% T|
|00003a70| 68 69 73 20 70 61 63 6b | 61 67 65 20 63 61 6e 20 |his pack|age can |
|00003a80| 6f 6e 6c 79 20 62 65 20 | 75 73 65 64 20 77 69 74 |only be |used wit|
|00003a90| 68 20 5c 4c 61 54 65 58 | 65 2c 20 73 6f 0a 25 20 |h \LaTeX|e, so.% |
|00003aa0| 20 20 20 61 6e 20 61 70 | 70 72 6f 70 72 69 61 74 | an ap|propriat|
|00003ab0| 65 20 6d 65 73 73 61 67 | 65 20 69 73 20 64 69 73 |e messag|e is dis|
|00003ac0| 70 6c 61 79 65 64 20 77 | 68 65 6e 20 61 6e 6f 74 |played w|hen anot|
|00003ad0| 68 65 72 0a 25 20 20 20 | 20 66 6f 72 6d 61 74 20 |her.% | format |
|00003ae0| 69 73 20 75 73 65 64 5c | 66 6f 6f 74 6e 6f 74 65 |is used\|footnote|
|00003af0| 7b 48 6f 77 65 76 65 72 | 2c 20 73 6f 6d 65 20 63 |{However|, some c|
|00003b00| 6f 64 65 20 69 73 20 69 | 6e 73 65 72 74 65 64 0a |ode is i|nserted.|
|00003b10| 25 20 20 20 20 74 6f 20 | 61 6c 6c 6f 77 20 69 74 |% to |allow it|
|00003b20| 73 20 75 73 65 20 77 69 | 74 68 20 70 6c 61 69 6e |s use wi|th plain|
|00003b30| 20 5c 70 72 6f 74 65 63 | 74 5c 54 65 58 7d 2e 0a | \protec|t\TeX}..|
|00003b40| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00003b50| 6f 63 6f 64 65 7d 0a 25 | 3c 2a 74 65 78 74 6d 65 |ocode}.%|<*textme|
|00003b60| 72 67 3e 0a 5c 4e 65 65 | 64 73 54 65 58 46 6f 72 |rg>.\Nee|dsTeXFor|
|00003b70| 6d 61 74 7b 4c 61 54 65 | 58 32 65 7d 5b 31 39 39 |mat{LaTe|X2e}[199|
|00003b80| 34 2f 30 31 2f 30 31 5d | 0a 25 20 20 20 20 5c 65 |4/01/01]|.% \e|
|00003b90| 6e 64 7b 6d 61 63 72 6f | 63 6f 64 65 7d 0a 25 0a |nd{macro|code}.%.|
|00003ba0| 25 20 20 20 20 41 6e 6e | 6f 75 6e 63 65 20 74 68 |% Ann|ounce th|
|00003bb0| 65 20 70 61 63 6b 61 67 | 65 20 6e 61 6d 65 20 61 |e packag|e name a|
|00003bc0| 6e 64 20 69 74 73 20 76 | 65 72 73 69 6f 6e 3a 0a |nd its v|ersion:.|
|00003bd0| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00003be0| 6f 63 6f 64 65 7d 0a 5c | 50 72 6f 76 69 64 65 73 |ocode}.\|Provides|
|00003bf0| 50 61 63 6b 61 67 65 7b | 74 65 78 74 6d 65 72 67 |Package{|textmerg|
|00003c00| 7d 5b 5c 66 69 6c 65 64 | 61 74 65 5d 0a 25 20 20 |}[\filed|ate].% |
|00003c10| 20 20 5c 65 6e 64 7b 6d | 61 63 72 6f 63 6f 64 65 | \end{m|acrocode|
|00003c20| 7d 0a 25 0a 25 20 20 20 | 20 20 41 6e 64 20 64 69 |}.%.% | And di|
|00003c30| 73 70 6c 61 79 20 69 74 | 20 6f 6e 20 74 68 65 20 |splay it| on the |
|00003c40| 74 65 72 6d 69 6e 61 6c | 20 28 61 6e 64 20 74 68 |terminal| (and th|
|00003c50| 65 20 6c 6f 67 20 66 69 | 6c 65 29 3a 0a 25 20 20 |e log fi|le):.% |
|00003c60| 20 20 5c 62 65 67 69 6e | 7b 6d 61 63 72 6f 63 6f | \begin|{macroco|
|00003c70| 64 65 7d 0a 5c 74 79 70 | 65 6f 75 74 7b 50 61 63 |de}.\typ|eout{Pac|
|00003c80| 6b 61 67 65 20 60 74 65 | 78 74 6d 65 72 67 27 20 |kage `te|xtmerg' |
|00003c90| 3c 5c 66 69 6c 65 64 61 | 74 65 3e 2e 7d 0a 5c 74 |<\fileda|te>.}.\t|
|00003ca0| 79 70 65 6f 75 74 7b 5c | 43 6f 70 79 72 69 67 68 |ypeout{\|Copyrigh|
|00003cb0| 74 7d 0a 25 3c 2f 74 65 | 78 74 6d 65 72 67 3e 0a |t}.%</te|xtmerg>.|
|00003cc0| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 63 |% \en|d{macroc|
|00003cd0| 6f 64 65 7d 0a 25 0a 25 | 20 20 20 20 54 68 65 20 |ode}.%.%| The |
|00003ce0| 70 6c 61 69 6e 20 5c 54 | 65 58 5c 20 76 65 72 73 |plain \T|eX\ vers|
|00003cf0| 69 6f 6e 20 77 69 6c 6c | 20 73 69 6d 70 6c 79 20 |ion will| simply |
|00003d00| 7c 5c 69 6e 70 75 74 7c | 20 74 68 69 73 20 70 61 ||\input|| this pa|
|00003d10| 63 6b 61 67 65 20 66 69 | 6c 65 2e 20 54 68 75 73 |ckage fi|le. Thus|
|00003d20| 0a 25 20 20 20 20 77 65 | 20 6e 65 65 64 20 74 6f |.% we| need to|
|00003d30| 20 6b 6e 6f 77 20 74 68 | 61 74 20 69 74 20 77 69 | know th|at it wi|
|00003d40| 6c 6c 20 75 6e 64 65 72 | 73 74 61 6e 64 20 65 76 |ll under|stand ev|
|00003d50| 65 72 79 74 68 69 6e 67 | 20 69 6e 20 74 68 65 20 |erything| in the |
|00003d60| 66 69 6c 65 2e 0a 25 20 | 20 20 20 5c 62 65 67 69 |file..% | \begi|
|00003d70| 6e 7b 6d 61 63 72 6f 63 | 6f 64 65 7d 0a 25 3c 2a |n{macroc|ode}.%<*|
|00003d80| 70 6c 61 69 6e 3e 0a 5c | 64 65 66 5c 4e 65 65 64 |plain>.\|def\Need|
|00003d90| 73 54 65 58 46 6f 72 6d | 61 74 23 31 5b 23 32 5d |sTeXForm|at#1[#2]|
|00003da0| 7b 7d 0a 5c 64 65 66 5c | 50 72 6f 76 69 64 65 73 |{}.\def\|Provides|
|00003db0| 50 61 63 6b 61 67 65 23 | 31 5b 23 32 5d 7b 7d 0a |Package#|1[#2]{}.|
|00003dc0| 5c 64 65 66 5c 74 79 70 | 65 6f 75 74 23 31 7b 5c |\def\typ|eout#1{\|
|00003dd0| 69 6d 6d 65 64 69 61 74 | 65 5c 77 72 69 74 65 30 |immediat|e\write0|
|00003de0| 7b 23 31 7d 7d 0a 5c 69 | 6e 70 75 74 20 74 65 78 |{#1}}.\i|nput tex|
|00003df0| 74 6d 65 72 67 2e 73 74 | 79 0a 25 3c 2f 70 6c 61 |tmerg.st|y.%</pla|
|00003e00| 69 6e 3e 0a 25 20 20 20 | 20 5c 65 6e 64 7b 6d 61 |in>.% | \end{ma|
|00003e10| 63 72 6f 63 6f 64 65 7d | 0a 25 0a 25 0a 25 5c 73 |crocode}|.%.%.%\s|
|00003e20| 65 63 74 69 6f 6e 7b 49 | 6d 70 6c 65 6d 65 6e 74 |ection{I|mplement|
|00003e30| 61 74 69 6f 6e 20 6f 66 | 20 74 68 65 20 73 69 6d |ation of| the sim|
|00003e40| 70 6c 65 20 63 61 73 65 | 7d 0a 25 0a 25 20 20 20 |ple case|}.%.% |
|00003e50| 20 5c 62 65 67 69 6e 7b | 6d 61 63 72 6f 7d 7b 5c | \begin{|macro}{\|
|00003e60| 67 6c 65 74 7d 0a 25 46 | 6f 72 20 63 6f 6e 76 65 |glet}.%F|or conve|
|00003e70| 6e 69 65 6e 63 65 20 77 | 65 20 64 65 66 69 6e 65 |nience w|e define|
|00003e80| 20 61 20 66 72 65 71 75 | 65 6e 74 6c 79 20 75 73 | a frequ|ently us|
|00003e90| 65 64 20 63 6f 6d 62 69 | 6e 61 74 69 6f 6e 20 68 |ed combi|nation h|
|00003ea0| 65 72 65 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ere..% | \begin|
|00003eb0| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 25 3c 2a 74 |{macroco|de}.%<*t|
|00003ec0| 65 78 74 6d 65 72 67 3e | 0a 5c 64 65 66 5c 67 6c |extmerg>|.\def\gl|
|00003ed0| 65 74 7b 5c 67 6c 6f 62 | 61 6c 5c 6c 65 74 7d 0a |et{\glob|al\let}.|
|00003ee0| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 63 |% \en|d{macroc|
|00003ef0| 6f 64 65 7d 0a 25 20 20 | 20 20 5c 65 6e 64 7b 6d |ode}.% | \end{m|
|00003f00| 61 63 72 6f 7d 0a 25 0a | 25 20 20 20 20 5c 62 65 |acro}.%.|% \be|
|00003f10| 67 69 6e 7b 6d 61 63 72 | 6f 7d 7b 5c 4d 65 72 67 |gin{macr|o}{\Merg|
|00003f20| 65 46 69 6c 65 7d 0a 25 | 20 20 20 20 5c 62 65 67 |eFile}.%| \beg|
|00003f30| 69 6e 7b 6d 61 63 72 6f | 7d 7b 5c 49 6e 70 75 74 |in{macro|}{\Input|
|00003f40| 46 69 6c 65 7d 0a 25 54 | 68 65 20 73 75 62 73 69 |File}.%T|he subsi|
|00003f50| 64 69 61 72 79 20 6d 65 | 72 67 65 20 66 69 6c 65 |diary me|rge file|
|00003f60| 20 69 73 20 64 65 66 69 | 6e 65 64 20 6e 65 78 74 | is defi|ned next|
|00003f70| 2e 20 41 20 6d 61 63 72 | 6f 20 69 73 20 74 68 65 |. A macr|o is the|
|00003f80| 6e 20 64 65 66 69 6e 65 | 64 20 74 68 61 74 0a 25 |n define|d that.%|
|00003f90| 61 74 74 65 6d 70 74 73 | 20 74 6f 20 6f 70 65 6e |attempts| to open|
|00003fa0| 20 69 74 20 66 6f 72 20 | 72 65 61 64 69 6e 67 2e | it for |reading.|
|00003fb0| 20 49 66 20 74 68 61 74 | 20 69 73 20 75 6e 73 75 | If that| is unsu|
|00003fc0| 63 63 65 73 73 66 75 6c | 2c 20 74 68 65 20 66 69 |ccessful|, the fi|
|00003fd0| 6c 65 20 69 73 0a 25 63 | 6c 6f 73 65 64 20 61 6e |le is.%c|losed an|
|00003fe0| 64 20 61 6e 20 65 72 72 | 6f 72 20 6d 65 73 73 61 |d an err|or messa|
|00003ff0| 67 65 20 69 73 20 69 73 | 73 75 65 64 2e 0a 25 20 |ge is is|sued..% |
|00004000| 20 20 20 5c 62 65 67 69 | 6e 7b 6d 61 63 72 6f 63 | \begi|n{macroc|
|00004010| 6f 64 65 7d 0a 5c 6e 65 | 77 72 65 61 64 5c 4d 65 |ode}.\ne|wread\Me|
|00004020| 72 67 65 46 69 6c 65 0a | 5c 64 65 66 5c 49 6e 70 |rgeFile.|\def\Inp|
|00004030| 75 74 46 69 6c 65 23 31 | 7b 25 0a 20 20 20 5c 6f |utFile#1|{%. \o|
|00004040| 70 65 6e 69 6e 5c 4d 65 | 72 67 65 46 69 6c 65 3d |penin\Me|rgeFile=|
|00004050| 23 31 0a 20 20 20 5c 69 | 66 65 6f 66 5c 4d 65 72 |#1. \i|feof\Mer|
|00004060| 67 65 46 69 6c 65 0a 20 | 20 20 5c 65 72 72 6d 65 |geFile. | \errme|
|00004070| 73 73 61 67 65 7b 45 6d | 70 74 79 20 6d 65 72 67 |ssage{Em|pty merg|
|00004080| 65 20 66 69 6c 65 7d 25 | 0a 20 20 20 5c 63 6c 6f |e file}%|. \clo|
|00004090| 73 65 69 6e 5c 4d 65 72 | 67 65 46 69 6c 65 0a 20 |sein\Mer|geFile. |
|000040a0| 20 20 5c 6c 6f 6e 67 5c | 64 65 66 5c 4d 61 6b 65 | \long\|def\Make|
|000040b0| 54 65 6d 70 6c 61 74 65 | 23 23 31 7b 25 0a 20 20 |Template|##1{%. |
|000040c0| 20 20 20 20 5c 64 65 66 | 5c 54 65 6d 70 6c 61 74 | \def|\Templat|
|000040d0| 65 7b 7d 7d 25 0a 20 20 | 20 5c 65 6c 73 65 5c 47 |e{}}%. | \else\G|
|000040e0| 65 74 49 6e 70 75 74 5c | 66 69 7d 0a 25 20 20 20 |etInput\|fi}.% |
|000040f0| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 63 6f 64 65 7d | \end{ma|crocode}|
|00004100| 0a 25 20 20 20 20 5c 65 | 6e 64 7b 6d 61 63 72 6f |.% \e|nd{macro|
|00004110| 7d 0a 25 20 20 20 20 5c | 65 6e 64 7b 6d 61 63 72 |}.% \|end{macr|
|00004120| 6f 7d 0a 25 54 68 65 20 | 63 6f 6d 6d 61 6e 64 20 |o}.%The |command |
|00004130| 7c 5c 4d 61 6b 65 54 65 | 6d 70 6c 61 74 65 7c 20 ||\MakeTe|mplate| |
|00004140| 77 69 6c 6c 20 62 65 20 | 75 73 65 64 20 6c 61 74 |will be |used lat|
|00004150| 65 72 20 74 6f 20 67 65 | 6e 65 72 61 74 65 20 74 |er to ge|nerate t|
|00004160| 68 65 20 62 6f 64 79 0a | 25 6f 66 20 74 68 65 20 |he body.|%of the |
|00004170| 66 6f 72 6d 20 69 6e 74 | 6f 20 77 68 69 63 68 20 |form int|o which |
|00004180| 66 69 65 6c 64 73 20 61 | 72 65 20 69 6e 73 65 72 |fields a|re inser|
|00004190| 74 65 64 2e 20 57 65 20 | 72 65 64 65 66 69 6e 65 |ted. We |redefine|
|000041a0| 20 69 74 20 69 66 20 74 | 68 65 20 66 69 6c 65 0a | it if t|he file.|
|000041b0| 25 69 73 20 65 6d 70 74 | 79 20 73 6f 20 74 68 61 |%is empt|y so tha|
|000041c0| 74 20 69 74 20 70 72 6f | 64 75 63 65 73 20 6e 6f |t it pro|duces no|
|000041d0| 20 74 65 78 74 2e 0a 25 | 0a 25 20 20 20 20 5c 62 | text..%|.% \b|
|000041e0| 65 67 69 6e 7b 6d 61 63 | 72 6f 7d 7b 5c 47 65 74 |egin{mac|ro}{\Get|
|000041f0| 49 6e 70 75 74 7d 0a 25 | 42 65 63 61 75 73 65 20 |Input}.%|Because |
|00004200| 74 68 65 20 63 6f 6e 64 | 69 74 69 6f 6e 61 6c 20 |the cond|itional |
|00004210| 7c 5c 69 66 65 6f 66 7c | 20 64 6f 65 73 20 6e 6f ||\ifeof|| does no|
|00004220| 74 20 72 65 74 75 72 6e | 20 74 72 75 65 20 75 6e |t return| true un|
|00004230| 74 69 6c 20 61 66 74 65 | 72 20 61 6e 0a 25 75 6e |til afte|r an.%un|
|00004240| 73 75 63 63 65 73 73 66 | 75 6c 20 72 65 61 64 20 |successf|ul read |
|00004250| 6f 70 65 72 61 74 69 6f | 6e 2c 20 61 20 6d 65 63 |operatio|n, a mec|
|00004260| 68 61 6e 69 73 6d 20 6f | 66 20 6c 6f 6f 6b 69 6e |hanism o|f lookin|
|00004270| 67 20 61 68 65 61 64 20 | 69 73 20 75 73 65 64 20 |g ahead |is used |
|00004280| 77 68 69 63 68 20 69 73 | 0a 25 73 69 6d 69 6c 61 |which is|.%simila|
|00004290| 72 20 74 6f 20 74 68 61 | 74 20 66 6f 75 6e 64 20 |r to tha|t found |
|000042a0| 69 6e 20 50 61 73 63 61 | 6c 2e 0a 25 20 20 20 20 |in Pasca|l..% |
|000042b0| 5c 62 65 67 69 6e 7b 6d | 61 63 72 6f 63 6f 64 65 |\begin{m|acrocode|
|000042c0| 7d 0a 5c 64 65 66 5c 47 | 65 74 49 6e 70 75 74 7b |}.\def\G|etInput{|
|000042d0| 7b 5c 65 6e 64 6c 69 6e | 65 63 68 61 72 3d 2d 31 |{\endlin|echar=-1|
|000042e0| 0a 20 20 20 5c 67 6c 6f | 62 61 6c 5c 72 65 61 64 |. \glo|bal\read|
|000042f0| 5c 4d 65 72 67 65 46 69 | 6c 65 20 74 6f 5c 49 6e |\MergeFi|le to\In|
|00004300| 70 75 74 42 75 66 66 65 | 72 7d 7d 0a 25 20 20 20 |putBuffe|r}}.% |
|00004310| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 63 6f 64 65 7d | \end{ma|crocode}|
|00004320| 0a 25 20 20 20 20 5c 65 | 6e 64 7b 6d 61 63 72 6f |.% \e|nd{macro|
|00004330| 7d 0a 25 0a 25 20 20 20 | 20 5c 62 65 67 69 6e 7b |}.%.% | \begin{|
|00004340| 6d 61 63 72 6f 7d 7b 5c | 53 65 65 49 66 45 6f 66 |macro}{\|SeeIfEof|
|00004350| 7d 0a 25 20 20 20 20 5c | 62 65 67 69 6e 7b 6d 61 |}.% \|begin{ma|
|00004360| 63 72 6f 7d 7b 5c 4c 6f | 6f 6b 41 67 61 69 6e 7d |cro}{\Lo|okAgain}|
|00004370| 0a 25 57 65 20 73 65 74 | 20 75 70 20 61 20 6d 65 |.%We set| up a me|
|00004380| 63 68 61 6e 69 73 6d 20 | 66 6f 72 20 64 65 63 69 |chanism |for deci|
|00004390| 64 69 6e 67 20 77 68 65 | 74 68 65 72 20 6f 72 20 |ding whe|ther or |
|000043a0| 6e 6f 74 20 77 65 20 68 | 61 76 65 0a 25 65 78 68 |not we h|ave.%exh|
|000043b0| 61 75 73 74 65 64 20 74 | 68 65 20 6d 65 72 67 65 |austed t|he merge|
|000043c0| 20 66 69 6c 65 2e 20 49 | 74 20 66 6f 72 63 65 73 | file. I|t forces|
|000043d0| 20 7c 5c 69 66 65 6f 66 | 7c 20 74 6f 20 72 65 74 | |\ifeof|| to ret|
|000043e0| 75 72 6e 20 74 72 75 65 | 0a 25 62 79 20 73 6b 69 |urn true|.%by ski|
|000043f0| 70 70 69 6e 67 20 6f 76 | 65 72 20 62 6c 61 6e 6b |pping ov|er blank|
|00004400| 20 6c 69 6e 65 73 2e 0a | 25 20 20 20 20 5c 62 65 | lines..|% \be|
|00004410| 67 69 6e 7b 6d 61 63 72 | 6f 63 6f 64 65 7d 0a 5c |gin{macr|ocode}.\|
|00004420| 64 65 66 5c 53 65 65 49 | 66 45 6f 66 7b 25 0a 20 |def\SeeI|fEof{%. |
|00004430| 20 20 5c 6c 65 74 5c 4e | 65 78 74 4c 6f 6f 6b 5c | \let\N|extLook\|
|00004440| 72 65 6c 61 78 0a 20 20 | 20 5c 69 66 65 6f 66 5c |relax. | \ifeof\|
|00004450| 4d 65 72 67 65 46 69 6c | 65 0a 20 20 20 5c 65 6c |MergeFil|e. \el|
|00004460| 73 65 0a 20 20 20 20 20 | 20 5c 69 66 78 5c 49 6e |se. | \ifx\In|
|00004470| 70 75 74 42 75 66 66 65 | 72 5c 65 6d 70 74 79 0a |putBuffe|r\empty.|
|00004480| 20 20 20 20 20 20 20 20 | 20 5c 4c 6f 6f 6b 41 67 | | \LookAg|
|00004490| 61 69 6e 0a 20 20 20 20 | 20 20 5c 66 69 0a 20 20 |ain. | \fi. |
|000044a0| 20 5c 66 69 0a 20 20 20 | 5c 4e 65 78 74 4c 6f 6f | \fi. |\NextLoo|
|000044b0| 6b 7d 0a 5c 64 65 66 5c | 4c 6f 6f 6b 41 67 61 69 |k}.\def\|LookAgai|
|000044c0| 6e 7b 5c 47 65 74 49 6e | 70 75 74 0a 20 20 20 5c |n{\GetIn|put. \|
|000044d0| 6c 65 74 5c 4e 65 78 74 | 4c 6f 6f 6b 5c 53 65 65 |let\Next|Look\See|
|000044e0| 49 66 45 6f 66 7d 0a 25 | 20 20 20 20 5c 65 6e 64 |IfEof}.%| \end|
|000044f0| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 25 20 20 20 |{macroco|de}.% |
|00004500| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 7d 0a 25 20 20 | \end{ma|cro}.% |
|00004510| 20 20 5c 65 6e 64 7b 6d | 61 63 72 6f 7d 0a 25 0a | \end{m|acro}.%.|
|00004520| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00004530| 6f 7d 7b 5c 69 66 4e 6f | 6e 42 6c 61 6e 6b 7d 0a |o}{\ifNo|nBlank}.|
|00004540| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00004550| 6f 7d 7b 5c 41 6c 6c 6f | 77 42 6c 61 6e 6b 7d 0a |o}{\Allo|wBlank}.|
|00004560| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00004570| 6f 7d 7b 5c 44 6f 6e 74 | 41 6c 6c 6f 77 42 6c 61 |o}{\Dont|AllowBla|
|00004580| 6e 6b 7d 0a 25 57 65 20 | 63 61 6e 20 6e 6f 77 20 |nk}.%We |can now |
|00004590| 70 72 65 70 61 72 65 20 | 74 6f 20 72 65 61 64 20 |prepare |to read |
|000045a0| 61 63 74 75 61 6c 20 66 | 69 65 6c 64 73 20 66 72 |actual f|ields fr|
|000045b0| 6f 6d 20 74 68 65 20 6d | 65 72 67 65 20 66 69 6c |om the m|erge fil|
|000045c0| 65 2e 20 41 20 63 6f 6e | 64 69 74 69 6f 6e 61 6c |e. A con|ditional|
|000045d0| 0a 25 69 73 20 75 73 65 | 64 20 74 6f 20 69 6e 64 |.%is use|d to ind|
|000045e0| 69 63 61 74 65 20 77 68 | 65 74 68 65 72 20 6f 72 |icate wh|ether or|
|000045f0| 20 6e 6f 74 20 74 68 65 | 20 66 69 65 6c 64 20 77 | not the| field w|
|00004600| 65 20 61 72 65 20 61 62 | 6f 75 74 20 74 6f 20 72 |e are ab|out to r|
|00004610| 65 61 64 20 69 73 0a 25 | 61 6c 6c 6f 77 65 64 20 |ead is.%|allowed |
|00004620| 74 6f 20 62 65 20 62 6c | 61 6e 6b 2e 20 57 65 20 |to be bl|ank. We |
|00004630| 61 6c 73 6f 20 73 65 74 | 20 75 70 20 61 20 6d 65 |also set| up a me|
|00004640| 63 68 61 6e 69 73 6d 20 | 66 6f 72 20 63 68 61 6e |chanism |for chan|
|00004650| 67 69 6e 67 20 69 74 73 | 20 76 61 6c 75 65 2e 0a |ging its| value..|
|00004660| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00004670| 6f 63 6f 64 65 7d 0a 5c | 6e 65 77 69 66 5c 69 66 |ocode}.\|newif\if|
|00004680| 4e 6f 6e 42 6c 61 6e 6b | 20 5c 4e 6f 6e 42 6c 61 |NonBlank| \NonBla|
|00004690| 6e 6b 66 61 6c 73 65 0a | 5c 64 65 66 5c 41 6c 6c |nkfalse.|\def\All|
|000046a0| 6f 77 42 6c 61 6e 6b 7b | 5c 67 6c 6f 62 61 6c 5c |owBlank{|\global\|
|000046b0| 4e 6f 6e 42 6c 61 6e 6b | 66 61 6c 73 65 7d 0a 5c |NonBlank|false}.\|
|000046c0| 64 65 66 5c 44 6f 6e 74 | 41 6c 6c 6f 77 42 6c 61 |def\Dont|AllowBla|
|000046d0| 6e 6b 7b 5c 67 6c 6f 62 | 61 6c 5c 4e 6f 6e 42 6c |nk{\glob|al\NonBl|
|000046e0| 61 6e 6b 74 72 75 65 7d | 0a 25 20 20 20 20 5c 65 |anktrue}|.% \e|
|000046f0| 6e 64 7b 6d 61 63 72 6f | 63 6f 64 65 7d 0a 25 20 |nd{macro|code}.% |
|00004700| 20 20 20 5c 65 6e 64 7b | 6d 61 63 72 6f 7d 0a 25 | \end{|macro}.%|
|00004710| 20 20 20 20 5c 65 6e 64 | 7b 6d 61 63 72 6f 7d 0a | \end|{macro}.|
|00004720| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 7d |% \en|d{macro}|
|00004730| 0a 25 0a 25 20 20 20 20 | 5c 62 65 67 69 6e 7b 6d |.%.% |\begin{m|
|00004740| 61 63 72 6f 7d 7b 5c 52 | 65 61 64 49 6e 7d 0a 25 |acro}{\R|eadIn}.%|
|00004750| 20 20 20 20 5c 62 65 67 | 69 6e 7b 6d 61 63 72 6f | \beg|in{macro|
|00004760| 7d 7b 5c 4d 69 73 73 69 | 6e 67 46 69 65 6c 64 7d |}{\Missi|ngField}|
|00004770| 0a 25 46 69 65 6c 64 73 | 20 61 72 65 20 61 63 74 |.%Fields| are act|
|00004780| 75 61 6c 6c 79 20 72 65 | 61 64 20 62 79 20 6d 65 |ually re|ad by me|
|00004790| 61 6e 73 20 6f 66 20 74 | 68 65 20 66 6f 6c 6c 6f |ans of t|he follo|
|000047a0| 77 69 6e 67 20 63 6f 6d | 6d 61 6e 64 2e 20 49 74 |wing com|mand. It|
|000047b0| 73 20 6f 6e 6c 79 0a 25 | 70 61 72 61 6d 65 74 65 |s only.%|paramete|
|000047c0| 72 20 69 73 20 74 68 65 | 20 6e 61 6d 65 20 6f 66 |r is the| name of|
|000047d0| 20 74 68 65 20 63 6f 6e | 74 72 6f 6c 20 73 65 71 | the con|trol seq|
|000047e0| 75 65 6e 63 65 20 69 6e | 74 6f 20 77 68 69 63 68 |uence in|to which|
|000047f0| 20 74 68 65 20 66 69 65 | 6c 64 20 69 73 0a 25 72 | the fie|ld is.%r|
|00004800| 65 61 64 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ead..% | \begin|
|00004810| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 5c 64 65 66 |{macroco|de}.\def|
|00004820| 5c 52 65 61 64 49 6e 23 | 31 7b 25 0a 20 20 20 5c |\ReadIn#|1{%. \|
|00004830| 69 66 4e 6f 6e 42 6c 61 | 6e 6b 5c 53 65 65 49 66 |ifNonBla|nk\SeeIf|
|00004840| 45 6f 66 5c 66 69 0a 20 | 20 20 5c 69 66 65 6f 66 |Eof\fi. | \ifeof|
|00004850| 5c 4d 65 72 67 65 46 69 | 6c 65 0a 20 20 20 20 20 |\MergeFi|le. |
|00004860| 20 5c 67 64 65 66 23 31 | 7b 3f 3f 7d 5c 4d 69 73 | \gdef#1|{??}\Mis|
|00004870| 73 69 6e 67 46 69 65 6c | 64 0a 20 20 20 5c 65 6c |singFiel|d. \el|
|00004880| 73 65 0a 20 20 20 20 20 | 20 5c 67 6c 65 74 23 31 |se. | \glet#1|
|00004890| 5c 49 6e 70 75 74 42 75 | 66 66 65 72 0a 20 20 20 |\InputBu|ffer. |
|000048a0| 20 20 20 5c 47 65 74 49 | 6e 70 75 74 0a 20 20 20 | \GetI|nput. |
|000048b0| 5c 66 69 7d 0a 5c 64 65 | 66 5c 4d 69 73 73 69 6e |\fi}.\de|f\Missin|
|000048c0| 67 46 69 65 6c 64 7b 25 | 0a 20 20 20 5c 6d 65 73 |gField{%|. \mes|
|000048d0| 73 61 67 65 7b 4d 69 73 | 73 69 6e 67 20 66 69 65 |sage{Mis|sing fie|
|000048e0| 6c 64 20 69 6e 20 66 69 | 6c 65 7d 7d 0a 25 20 20 |ld in fi|le}}.% |
|000048f0| 20 20 5c 65 6e 64 7b 6d | 61 63 72 6f 63 6f 64 65 | \end{m|acrocode|
|00004900| 7d 0a 25 20 20 20 20 5c | 65 6e 64 7b 6d 61 63 72 |}.% \|end{macr|
|00004910| 6f 7d 0a 25 20 20 20 20 | 5c 65 6e 64 7b 6d 61 63 |o}.% |\end{mac|
|00004920| 72 6f 7d 0a 25 0a 25 20 | 20 20 20 5c 62 65 67 69 |ro}.%.% | \begi|
|00004930| 6e 7b 6d 61 63 72 6f 7d | 7b 5c 47 6c 6f 62 61 6c |n{macro}|{\Global|
|00004940| 46 69 65 6c 64 73 7d 0a | 25 20 20 20 20 5c 62 65 |Fields}.|% \be|
|00004950| 67 69 6e 7b 6d 61 63 72 | 6f 7d 7b 5c 46 69 65 6c |gin{macr|o}{\Fiel|
|00004960| 64 73 7d 0a 25 54 68 65 | 20 7c 5c 46 69 65 6c 64 |ds}.%The| |\Field|
|00004970| 73 7c 20 63 6f 6d 6d 61 | 6e 64 20 70 6c 61 63 65 |s| comma|nd place|
|00004980| 73 20 69 74 73 20 70 61 | 72 61 6d 65 74 65 72 20 |s its pa|rameter |
|00004990| 69 6e 74 6f 20 61 20 74 | 6f 6b 65 6e 0a 25 72 65 |into a t|oken.%re|
|000049a0| 67 69 73 74 65 72 20 63 | 61 6c 6c 65 64 20 7c 5c |gister c|alled |\|
|000049b0| 47 6c 6f 62 61 6c 46 69 | 65 6c 64 73 7c 2e 0a 25 |GlobalFi|elds|..%|
|000049c0| 54 68 69 73 20 63 6f 6d | 6d 61 6e 64 20 77 69 6c |This com|mand wil|
|000049d0| 6c 20 62 65 20 72 65 64 | 65 66 69 6e 65 64 20 62 |l be red|efined b|
|000049e0| 79 20 74 68 65 20 7c 5c | 4d 65 72 67 65 7c 20 63 |y the |\|Merge| c|
|000049f0| 6f 6d 6d 61 6e 64 2e 0a | 25 20 20 20 20 5c 62 65 |ommand..|% \be|
|00004a00| 67 69 6e 7b 6d 61 63 72 | 6f 63 6f 64 65 7d 0a 5c |gin{macr|ocode}.\|
|00004a10| 6e 65 77 74 6f 6b 73 5c | 47 6c 6f 62 61 6c 46 69 |newtoks\|GlobalFi|
|00004a20| 65 6c 64 73 0a 5c 64 65 | 66 5c 46 69 65 6c 64 73 |elds.\de|f\Fields|
|00004a30| 23 31 7b 5c 47 6c 6f 62 | 61 6c 46 69 65 6c 64 73 |#1{\Glob|alFields|
|00004a40| 7b 23 31 7d 7d 0a 25 20 | 20 20 20 5c 65 6e 64 7b |{#1}}.% | \end{|
|00004a50| 6d 61 63 72 6f 63 6f 64 | 65 7d 0a 25 20 20 20 20 |macrocod|e}.% |
|00004a60| 5c 65 6e 64 7b 6d 61 63 | 72 6f 7d 0a 25 20 20 20 |\end{mac|ro}.% |
|00004a70| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 7d 0a 25 0a 25 | \end{ma|cro}.%.%|
|00004a80| 20 20 20 20 5c 62 65 67 | 69 6e 7b 6d 61 63 72 6f | \beg|in{macro|
|00004a90| 7d 7b 5c 50 61 72 73 65 | 46 69 65 6c 64 73 7d 0a |}{\Parse|Fields}.|
|00004aa0| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00004ab0| 6f 7d 7b 5c 45 6e 64 50 | 61 72 73 65 46 69 65 6c |o}{\EndP|arseFiel|
|00004ac0| 64 73 7d 0a 25 57 68 65 | 6e 20 61 20 66 69 65 6c |ds}.%Whe|n a fiel|
|00004ad0| 64 20 74 6f 6b 65 6e 20 | 6c 69 73 74 20 69 73 20 |d token |list is |
|00004ae0| 72 65 61 64 2c 0a 25 65 | 61 63 68 20 69 6e 64 69 |read,.%e|ach indi|
|00004af0| 76 69 64 75 61 6c 20 74 | 6f 6b 65 6e 20 77 69 74 |vidual t|oken wit|
|00004b00| 68 69 6e 20 69 74 20 6d | 75 73 74 20 62 65 20 65 |hin it m|ust be e|
|00004b10| 69 74 68 65 72 0a 25 72 | 65 61 64 20 61 73 20 61 |ither.%r|ead as a|
|00004b20| 20 66 69 65 6c 64 20 6f | 72 20 69 6e 74 65 72 70 | field o|r interp|
|00004b30| 72 65 74 65 64 20 61 73 | 20 61 20 62 6c 61 6e 6b |reted as| a blank|
|00004b40| 2f 6e 6f 6e 62 6c 61 6e | 6b 20 73 77 69 74 63 68 |/nonblan|k switch|
|00004b50| 2e 0a 25 54 68 65 20 6e | 65 78 74 20 74 6f 6b 65 |..%The n|ext toke|
|00004b60| 6e 20 69 73 20 74 68 65 | 6e 20 72 65 61 64 20 62 |n is the|n read b|
|00004b70| 79 20 74 61 69 6c 20 72 | 65 63 75 72 73 69 6f 6e |y tail r|ecursion|
|00004b80| 2e 0a 25 49 74 20 69 73 | 20 61 73 73 75 6d 65 64 |..%It is| assumed|
|00004b90| 20 74 68 61 74 20 74 68 | 65 20 66 69 6e 61 6c 20 | that th|e final |
|00004ba0| 74 6f 6b 65 6e 20 69 6e | 20 74 68 65 20 6c 69 73 |token in| the lis|
|00004bb0| 74 20 69 73 20 7c 5c 45 | 6e 64 50 61 72 73 65 46 |t is |\E|ndParseF|
|00004bc0| 69 65 6c 64 73 7c 2e 0a | 25 54 68 69 73 20 6d 75 |ields|..|%This mu|
|00004bd0| 73 74 20 62 65 20 64 65 | 66 69 6e 65 64 20 74 6f |st be de|fined to|
|00004be0| 20 65 78 70 61 6e 64 20 | 74 6f 20 73 6f 6d 65 74 | expand |to somet|
|00004bf0| 68 69 6e 67 20 75 6e 6c | 69 6b 65 6c 79 20 74 6f |hing unl|ikely to|
|00004c00| 20 62 65 20 72 65 61 64 | 20 61 73 20 61 0a 25 76 | be read| as a.%v|
|00004c10| 61 6c 75 65 20 6f 66 20 | 6f 6e 65 20 6f 66 20 74 |alue of |one of t|
|00004c20| 68 65 20 66 69 65 6c 64 | 73 2c 20 61 6e 64 20 73 |he field|s, and s|
|00004c30| 6f 20 77 65 20 7c 5c 6c | 65 74 7c 20 69 74 20 74 |o we |\l|et| it t|
|00004c40| 6f 20 7c 5c 50 61 72 73 | 65 46 69 65 6c 64 73 7c |o |\Pars|eFields||
|00004c50| 2e 0a 25 20 20 20 20 5c | 62 65 67 69 6e 7b 6d 61 |..% \|begin{ma|
|00004c60| 63 72 6f 63 6f 64 65 7d | 0a 5c 64 65 66 5c 50 61 |crocode}|.\def\Pa|
|00004c70| 72 73 65 46 69 65 6c 64 | 73 23 31 7b 25 0a 20 20 |rseField|s#1{%. |
|00004c80| 20 5c 69 66 78 23 31 5c | 45 6e 64 50 61 72 73 65 | \ifx#1\|EndParse|
|00004c90| 46 69 65 6c 64 73 0a 20 | 20 20 20 20 20 5c 6c 65 |Fields. | \le|
|00004ca0| 74 5c 4e 65 78 74 50 61 | 72 73 65 5c 72 65 6c 61 |t\NextPa|rse\rela|
|00004cb0| 78 0a 20 20 20 5c 65 6c | 73 65 0a 20 20 20 20 20 |x. \el|se. |
|00004cc0| 20 5c 6c 65 74 5c 4e 65 | 78 74 50 61 72 73 65 5c | \let\Ne|xtParse\|
|00004cd0| 50 61 72 73 65 46 69 65 | 6c 64 73 0a 20 20 20 20 |ParseFie|lds. |
|00004ce0| 20 20 5c 69 66 78 23 31 | 2b 5c 44 6f 6e 74 41 6c | \ifx#1|+\DontAl|
|00004cf0| 6c 6f 77 42 6c 61 6e 6b | 0a 20 20 20 20 20 20 5c |lowBlank|. \|
|00004d00| 65 6c 73 65 0a 20 20 20 | 20 20 20 20 20 20 5c 69 |else. | \i|
|00004d10| 66 78 23 31 2d 5c 41 6c | 6c 6f 77 42 6c 61 6e 6b |fx#1-\Al|lowBlank|
|00004d20| 0a 20 20 20 20 20 20 20 | 20 20 5c 65 6c 73 65 5c |. | \else\|
|00004d30| 52 65 61 64 49 6e 23 31 | 0a 20 20 20 20 20 20 20 |ReadIn#1|. |
|00004d40| 20 20 5c 66 69 0a 20 20 | 20 20 20 20 5c 66 69 0a | \fi. | \fi.|
|00004d50| 20 20 20 5c 66 69 5c 4e | 65 78 74 50 61 72 73 65 | \fi\N|extParse|
|00004d60| 7d 0a 5c 6c 65 74 5c 45 | 6e 64 50 61 72 73 65 46 |}.\let\E|ndParseF|
|00004d70| 69 65 6c 64 73 5c 50 61 | 72 73 65 46 69 65 6c 64 |ields\Pa|rseField|
|00004d80| 73 0a 25 20 20 20 20 5c | 65 6e 64 7b 6d 61 63 72 |s.% \|end{macr|
|00004d90| 6f 63 6f 64 65 7d 0a 25 | 20 20 20 20 5c 65 6e 64 |ocode}.%| \end|
|00004da0| 7b 6d 61 63 72 6f 7d 0a | 25 20 20 20 20 5c 65 6e |{macro}.|% \en|
|00004db0| 64 7b 6d 61 63 72 6f 7d | 0a 25 0a 25 20 20 20 20 |d{macro}|.%.% |
|00004dc0| 5c 62 65 67 69 6e 7b 6d | 61 63 72 6f 7d 7b 5c 52 |\begin{m|acro}{\R|
|00004dd0| 65 61 64 46 69 65 6c 64 | 73 7d 0a 25 57 65 20 61 |eadField|s}.%We a|
|00004de0| 70 70 6c 79 20 74 68 69 | 73 20 63 6f 6d 6d 61 6e |pply thi|s comman|
|00004df0| 64 20 74 6f 20 6f 75 72 | 20 74 6f 6b 65 6e 20 72 |d to our| token r|
|00004e00| 65 67 69 73 74 65 72 20 | 61 66 74 65 72 20 65 78 |egister |after ex|
|00004e10| 70 61 6e 64 69 6e 67 20 | 69 74 2e 0a 25 20 20 20 |panding |it..% |
|00004e20| 20 5c 62 65 67 69 6e 7b | 6d 61 63 72 6f 63 6f 64 | \begin{|macrocod|
|00004e30| 65 7d 0a 5c 64 65 66 5c | 52 65 61 64 46 69 65 6c |e}.\def\|ReadFiel|
|00004e40| 64 73 23 31 7b 5c 65 78 | 70 61 6e 64 61 66 74 65 |ds#1{\ex|pandafte|
|00004e50| 72 5c 50 61 72 73 65 46 | 69 65 6c 64 73 0a 20 20 |r\ParseF|ields. |
|00004e60| 20 5c 74 68 65 23 31 5c | 45 6e 64 50 61 72 73 65 | \the#1\|EndParse|
|00004e70| 46 69 65 6c 64 73 0a 20 | 20 20 5c 41 6c 6c 6f 77 |Fields. | \Allow|
|00004e80| 42 6c 61 6e 6b 7d 0a 25 | 20 20 20 20 5c 65 6e 64 |Blank}.%| \end|
|00004e90| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 25 20 20 20 |{macroco|de}.% |
|00004ea0| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 7d 0a 25 0a 25 | \end{ma|cro}.%.%|
|00004eb0| 20 20 20 20 5c 62 65 67 | 69 6e 7b 6d 61 63 72 6f | \beg|in{macro|
|00004ec0| 7d 7b 5c 4d 65 72 67 65 | 7d 0a 25 20 20 20 20 5c |}{\Merge|}.% \|
|00004ed0| 62 65 67 69 6e 7b 6d 61 | 63 72 6f 7d 7b 5c 4d 61 |begin{ma|cro}{\Ma|
|00004ee0| 6b 65 54 65 6d 70 6c 61 | 74 65 7d 0a 25 41 74 20 |keTempla|te}.%At |
|00004ef0| 6c 6f 6e 67 20 6c 61 73 | 74 20 77 65 20 61 72 65 |long las|t we are|
|00004f00| 20 72 65 61 64 79 20 74 | 6f 20 64 65 66 69 6e 65 | ready t|o define|
|00004f10| 20 74 68 65 20 7c 5c 4d | 65 72 67 65 7c 20 63 6f | the |\M|erge| co|
|00004f20| 6d 6d 61 6e 64 20 69 74 | 73 65 6c 66 2e 0a 25 54 |mmand it|self..%T|
|00004f30| 68 65 20 66 69 72 73 74 | 20 70 61 72 61 6d 65 74 |he first| paramet|
|00004f40| 65 72 20 69 73 20 74 68 | 65 20 66 69 6c 65 6e 61 |er is th|e filena|
|00004f50| 6d 65 20 6f 66 20 74 68 | 65 20 73 75 62 73 69 64 |me of th|e subsid|
|00004f60| 69 61 72 79 20 66 69 6c | 65 20 61 6e 64 20 74 68 |iary fil|e and th|
|00004f70| 65 20 73 65 63 6f 6e 64 | 0a 25 69 73 20 74 68 65 |e second|.%is the|
|00004f80| 20 74 65 6d 70 6c 61 74 | 65 20 6f 72 20 66 6f 72 | templat|e or for|
|00004f90| 6d 20 69 6e 74 6f 20 77 | 68 69 63 68 20 66 69 65 |m into w|hich fie|
|00004fa0| 6c 64 73 20 61 72 65 20 | 69 6e 73 65 72 74 65 64 |lds are |inserted|
|00004fb0| 2e 0a 25 53 69 6e 63 65 | 20 61 20 7c 5c 46 69 65 |..%Since| a |\Fie|
|00004fc0| 6c 64 73 7c 20 63 6f 6d | 6d 61 6e 64 20 77 69 74 |lds| com|mand wit|
|00004fd0| 68 69 6e 20 74 68 65 20 | 7c 5c 4d 65 72 67 65 7c |hin the ||\Merge||
|00004fe0| 20 74 65 78 74 20 69 73 | 20 6d 65 61 6e 74 0a 25 | text is| meant.%|
|00004ff0| 74 6f 20 61 63 74 20 69 | 6d 6d 65 64 69 61 74 65 |to act i|mmediate|
|00005000| 6c 79 20 6f 6e 20 74 68 | 65 20 74 6f 6b 65 6e 20 |ly on th|e token |
|00005010| 6c 69 73 74 20 74 68 61 | 74 20 66 6f 6c 6c 6f 77 |list tha|t follow|
|00005020| 73 20 69 74 2c 20 77 65 | 20 72 65 64 65 66 69 6e |s it, we| redefin|
|00005030| 65 20 69 74 0a 25 74 6f | 20 6f 70 65 72 61 74 65 |e it.%to| operate|
|00005040| 20 69 6e 20 61 20 64 69 | 66 66 65 72 65 6e 74 20 | in a di|fferent |
|00005050| 77 61 79 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |way..% | \begin|
|00005060| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 5c 6c 6f 6e |{macroco|de}.\lon|
|00005070| 67 5c 64 65 66 5c 4d 65 | 72 67 65 23 31 23 32 7b |g\def\Me|rge#1#2{|
|00005080| 5c 62 65 67 69 6e 67 72 | 6f 75 70 25 0a 20 20 20 |\begingr|oup%. |
|00005090| 5c 49 6e 70 75 74 46 69 | 6c 65 7b 23 31 7d 25 0a |\InputFi|le{#1}%.|
|000050a0| 20 20 20 5c 64 65 66 5c | 46 69 65 6c 64 73 23 23 | \def\|Fields##|
|000050b0| 31 7b 25 0a 20 20 20 20 | 20 20 5c 50 61 72 73 65 |1{%. | \Parse|
|000050c0| 46 69 65 6c 64 73 23 23 | 31 5c 45 6e 64 50 61 72 |Fields##|1\EndPar|
|000050d0| 73 65 46 69 65 6c 64 73 | 7d 25 0a 20 20 20 5c 4d |seFields|}%. \M|
|000050e0| 61 6b 65 54 65 6d 70 6c | 61 74 65 7b 23 32 7d 5c |akeTempl|ate{#2}\|
|000050f0| 49 74 65 72 61 74 65 7d | 0a 5c 6c 6f 6e 67 5c 64 |Iterate}|.\long\d|
|00005100| 65 66 5c 4d 61 6b 65 54 | 65 6d 70 6c 61 74 65 23 |ef\MakeT|emplate#|
|00005110| 31 7b 5c 64 65 66 5c 54 | 65 6d 70 6c 61 74 65 7b |1{\def\T|emplate{|
|00005120| 23 31 7d 7d 0a 25 20 20 | 20 20 5c 65 6e 64 7b 6d |#1}}.% | \end{m|
|00005130| 61 63 72 6f 63 6f 64 65 | 7d 0a 25 20 20 20 20 5c |acrocode|}.% \|
|00005140| 65 6e 64 7b 6d 61 63 72 | 6f 7d 0a 25 20 20 20 20 |end{macr|o}.% |
|00005150| 5c 65 6e 64 7b 6d 61 63 | 72 6f 7d 0a 25 54 68 65 |\end{mac|ro}.%The|
|00005160| 20 67 72 6f 75 70 69 6e | 67 20 6b 65 65 70 73 20 | groupin|g keeps |
|00005170| 61 6e 79 20 63 68 61 6e | 67 65 73 20 74 6f 20 74 |any chan|ges to t|
|00005180| 68 65 20 64 65 66 69 6e | 69 74 69 6f 6e 20 6f 66 |he defin|ition of|
|00005190| 20 7c 5c 4d 61 6b 65 54 | 65 6d 70 6c 61 74 65 7c | |\MakeT|emplate||
|000051a0| 0a 25 6c 6f 63 61 6c 20 | 74 6f 20 74 68 69 73 20 |.%local |to this |
|000051b0| 6d 65 72 67 65 2e 0a 25 | 54 68 75 73 20 73 65 76 |merge..%|Thus sev|
|000051c0| 65 72 61 6c 20 63 6f 6e | 73 65 63 75 74 69 76 65 |eral con|secutive|
|000051d0| 20 6d 65 72 67 65 73 20 | 63 61 6e 20 62 65 20 68 | merges |can be h|
|000051e0| 61 6e 64 6c 65 64 0a 25 | 77 69 74 68 69 6e 20 6f |andled.%|within o|
|000051f0| 6e 65 20 64 6f 63 75 6d | 65 6e 74 2e 0a 25 54 68 |ne docum|ent..%Th|
|00005200| 65 20 7c 5c 65 6e 64 67 | 72 6f 75 70 7c 20 69 73 |e |\endg|roup| is|
|00005210| 20 73 75 70 70 6c 69 65 | 64 20 62 79 20 74 68 65 | supplie|d by the|
|00005220| 20 6d 61 63 72 6f 20 7c | 5c 49 74 65 72 61 74 65 | macro ||\Iterate|
|00005230| 7c 0a 25 77 68 65 6e 20 | 74 68 65 20 6d 65 72 67 ||.%when |the merg|
|00005240| 65 20 66 69 6c 65 20 68 | 61 73 20 62 65 65 6e 20 |e file h|as been |
|00005250| 65 78 68 61 75 73 74 65 | 64 2e 0a 25 0a 25 20 20 |exhauste|d..%.% |
|00005260| 20 20 5c 62 65 67 69 6e | 7b 6d 61 63 72 6f 7d 7b | \begin|{macro}{|
|00005270| 5c 49 74 65 72 61 74 65 | 63 6f 75 6e 74 65 72 7d |\Iterate|counter}|
|00005280| 0a 25 20 20 20 20 5c 62 | 65 67 69 6e 7b 6d 61 63 |.% \b|egin{mac|
|00005290| 72 6f 7d 7b 5c 49 74 65 | 72 61 74 65 7d 0a 25 7c |ro}{\Ite|rate}.%||
|000052a0| 5c 49 74 65 72 61 74 65 | 7c 20 6d 75 73 74 20 72 |\Iterate|| must r|
|000052b0| 65 61 64 20 74 68 65 20 | 66 69 65 6c 64 73 20 77 |ead the |fields w|
|000052c0| 68 69 63 68 20 77 65 72 | 65 20 64 65 63 6c 61 72 |hich wer|e declar|
|000052d0| 65 64 20 62 65 66 6f 72 | 65 20 69 74 20 77 61 73 |ed befor|e it was|
|000052e0| 20 65 6e 74 65 72 65 64 | 2c 0a 25 73 75 62 73 74 | entered|,.%subst|
|000052f0| 69 74 75 74 65 20 74 68 | 65 6d 20 69 6e 74 6f 20 |itute th|em into |
|00005300| 69 74 73 20 74 65 6d 70 | 6c 61 74 65 20 61 6e 64 |its temp|late and|
|00005310| 20 72 65 70 65 61 74 20 | 69 74 73 65 6c 66 20 75 | repeat |itself u|
|00005320| 73 69 6e 67 20 74 61 69 | 6c 20 72 65 63 75 72 73 |sing tai|l recurs|
|00005330| 69 6f 6e 0a 25 69 66 20 | 74 68 65 20 65 6e 64 20 |ion.%if |the end |
|00005340| 6f 66 20 74 68 65 20 6d | 65 72 67 65 20 66 69 6c |of the m|erge fil|
|00005350| 65 20 68 61 73 20 6e 6f | 74 20 62 65 65 6e 20 65 |e has no|t been e|
|00005360| 6e 63 6f 75 6e 74 65 72 | 65 64 2e 0a 25 20 20 20 |ncounter|ed..% |
|00005370| 20 5c 62 65 67 69 6e 7b | 6d 61 63 72 6f 63 6f 64 | \begin{|macrocod|
|00005380| 65 7d 0a 5c 63 6f 75 6e | 74 64 65 66 5c 49 74 65 |e}.\coun|tdef\Ite|
|00005390| 72 61 74 65 63 6f 75 6e | 74 65 72 3d 32 0a 5c 49 |ratecoun|ter=2.\I|
|000053a0| 74 65 72 61 74 65 63 6f | 75 6e 74 65 72 3d 30 0a |terateco|unter=0.|
|000053b0| 5c 64 65 66 5c 49 74 65 | 72 61 74 65 7b 25 0a 20 |\def\Ite|rate{%. |
|000053c0| 20 20 5c 67 6c 6f 62 61 | 6c 5c 61 64 76 61 6e 63 | \globa|l\advanc|
|000053d0| 65 5c 49 74 65 72 61 74 | 65 63 6f 75 6e 74 65 72 |e\Iterat|ecounter|
|000053e0| 20 62 79 31 0a 20 20 20 | 5c 52 65 61 64 46 69 65 | by1. |\ReadFie|
|000053f0| 6c 64 73 5c 47 6c 6f 62 | 61 6c 46 69 65 6c 64 73 |lds\Glob|alFields|
|00005400| 0a 20 20 20 5c 54 65 6d | 70 6c 61 74 65 0a 20 20 |. \Tem|plate. |
|00005410| 20 5c 53 65 65 49 66 45 | 6f 66 0a 20 20 20 5c 69 | \SeeIfE|of. \i|
|00005420| 66 65 6f 66 5c 4d 65 72 | 67 65 46 69 6c 65 0a 20 |feof\Mer|geFile. |
|00005430| 20 20 20 20 20 5c 64 65 | 66 5c 4e 65 78 74 49 74 | \de|f\NextIt|
|00005440| 65 72 61 74 69 6f 6e 7b | 25 0a 20 20 20 20 20 20 |eration{|%. |
|00005450| 20 20 20 5c 65 6e 64 67 | 72 6f 75 70 5c 63 6c 6f | \endg|roup\clo|
|00005460| 73 65 69 6e 5c 4d 65 72 | 67 65 46 69 6c 65 7d 25 |sein\Mer|geFile}%|
|00005470| 0a 20 20 20 5c 65 6c 73 | 65 0a 20 20 20 20 20 20 |. \els|e. |
|00005480| 5c 6c 65 74 5c 4e 65 78 | 74 49 74 65 72 61 74 69 |\let\Nex|tIterati|
|00005490| 6f 6e 5c 49 74 65 72 61 | 74 65 0a 20 20 20 5c 66 |on\Itera|te. \f|
|000054a0| 69 0a 20 20 20 5c 4e 65 | 78 74 49 74 65 72 61 74 |i. \Ne|xtIterat|
|000054b0| 69 6f 6e 7d 0a 25 20 20 | 20 20 5c 65 6e 64 7b 6d |ion}.% | \end{m|
|000054c0| 61 63 72 6f 63 6f 64 65 | 7d 0a 25 20 20 20 20 5c |acrocode|}.% \|
|000054d0| 65 6e 64 7b 6d 61 63 72 | 6f 7d 0a 25 20 20 20 20 |end{macr|o}.% |
|000054e0| 5c 65 6e 64 7b 6d 61 63 | 72 6f 7d 0a 25 54 68 65 |\end{mac|ro}.%The|
|000054f0| 20 70 6f 69 6e 74 20 6f | 66 20 74 68 65 20 75 73 | point o|f the us|
|00005500| 65 20 6f 66 20 63 6f 75 | 6e 74 65 72 20 32 20 69 |e of cou|nter 2 i|
|00005510| 6e 20 74 68 65 20 61 62 | 6f 76 65 20 69 73 20 74 |n the ab|ove is t|
|00005520| 68 61 74 20 69 74 20 69 | 73 20 61 63 63 65 73 73 |hat it i|s access|
|00005530| 69 62 6c 65 20 74 6f 0a | 25 74 68 65 20 70 72 69 |ible to.|%the pri|
|00005540| 6e 74 20 64 72 69 76 65 | 72 20 66 6f 72 20 70 61 |nt drive|r for pa|
|00005550| 67 65 20 73 65 6c 65 63 | 74 69 6f 6e 2e 0a 25 41 |ge selec|tion..%A|
|00005560| 6e 79 6f 6e 65 20 77 68 | 6f 20 68 61 73 20 73 74 |nyone wh|o has st|
|00005570| 61 72 74 65 64 20 70 72 | 69 6e 74 69 6e 67 20 31 |arted pr|inting 1|
|00005580| 35 30 20 6c 65 74 74 65 | 72 73 2c 20 61 6c 6c 20 |50 lette|rs, all |
|00005590| 77 69 74 68 20 70 61 67 | 65 20 6e 75 6d 62 65 72 |with pag|e number|
|000055a0| 7e 31 2c 0a 25 6f 6e 6c | 79 20 74 6f 20 72 75 6e |~1,.%onl|y to run|
|000055b0| 20 6f 75 74 20 6f 66 20 | 70 61 70 65 72 20 68 61 | out of |paper ha|
|000055c0| 6c 66 20 77 61 79 2c 20 | 77 69 6c 6c 20 61 70 70 |lf way, |will app|
|000055d0| 72 65 63 69 61 74 65 20 | 74 68 65 20 75 73 65 20 |reciate |the use |
|000055e0| 6f 66 20 74 68 69 73 20 | 61 72 74 69 66 69 63 65 |of this |artifice|
|000055f0| 21 0a 25 0a 25 5c 73 65 | 63 74 69 6f 6e 7b 49 6d |!.%.%\se|ction{Im|
|00005600| 70 6c 65 6d 65 6e 74 61 | 74 69 6f 6e 20 6f 66 20 |plementa|tion of |
|00005610| 6d 65 72 67 65 64 20 74 | 61 62 6c 65 73 7d 0a 25 |merged t|ables}.%|
|00005620| 0a 25 20 20 20 20 5c 62 | 65 67 69 6e 7b 6d 61 63 |.% \b|egin{mac|
|00005630| 72 6f 7d 7b 5c 4d 75 6c | 74 69 43 6f 75 6e 74 7d |ro}{\Mul|tiCount}|
|00005640| 0a 25 20 20 20 20 5c 62 | 65 67 69 6e 7b 6d 61 63 |.% \b|egin{mac|
|00005650| 72 6f 7d 7b 5c 4d 61 78 | 43 6f 75 6e 74 7d 0a 25 |ro}{\Max|Count}.%|
|00005660| 20 20 20 20 5c 62 65 67 | 69 6e 7b 6d 61 63 72 6f | \beg|in{macro|
|00005670| 7d 7b 5c 69 66 53 74 61 | 72 74 4f 66 4c 69 73 74 |}{\ifSta|rtOfList|
|00005680| 7d 0a 25 57 65 20 73 65 | 74 20 75 70 20 74 77 6f |}.%We se|t up two|
|00005690| 20 63 6f 75 6e 74 65 72 | 73 2c 20 6f 6e 65 20 66 | counter|s, one f|
|000056a0| 6f 72 20 74 68 65 20 63 | 6f 6c 75 6d 6e 20 77 65 |or the c|olumn we|
|000056b0| 20 61 72 65 20 72 65 61 | 64 69 6e 67 20 61 6e 64 | are rea|ding and|
|000056c0| 20 74 68 65 0a 25 6f 74 | 68 65 72 20 66 6f 72 20 | the.%ot|her for |
|000056d0| 74 68 65 20 74 6f 74 61 | 6c 20 6e 75 6d 62 65 72 |the tota|l number|
|000056e0| 20 6f 66 20 63 6f 6c 75 | 6d 6e 73 20 69 6e 20 74 | of colu|mns in t|
|000056f0| 68 65 20 74 61 62 6c 65 | 2e 0a 25 57 65 20 61 6c |he table|..%We al|
|00005700| 73 6f 20 6e 65 65 64 20 | 61 20 63 6f 6e 64 69 74 |so need |a condit|
|00005710| 69 6f 6e 61 6c 20 74 6f | 20 6d 61 72 6b 20 74 68 |ional to| mark th|
|00005720| 65 20 73 74 61 72 74 20 | 6f 66 20 74 68 65 20 74 |e start |of the t|
|00005730| 61 62 6c 65 2c 20 73 6f | 20 74 68 61 74 0a 25 77 |able, so| that.%w|
|00005740| 65 20 74 65 72 6d 69 6e | 61 74 65 20 65 61 63 68 |e termin|ate each|
|00005750| 20 72 6f 77 20 63 6f 72 | 72 65 63 74 6c 79 20 77 | row cor|rectly w|
|00005760| 69 74 68 20 7c 5c 5c 7c | 20 6f 72 20 7c 5c 63 72 |ith |\\|| or |\cr|
|00005770| 7c 2c 20 6f 72 20 6e 6f | 74 68 69 6e 67 20 61 74 ||, or no|thing at|
|00005780| 20 61 6c 6c 0a 25 61 74 | 20 74 68 65 20 62 65 67 | all.%at| the beg|
|00005790| 69 6e 6e 69 6e 67 20 6f | 66 20 74 68 65 20 66 69 |inning o|f the fi|
|000057a0| 72 73 74 20 72 6f 77 2e | 0a 25 20 20 20 20 5c 62 |rst row.|.% \b|
|000057b0| 65 67 69 6e 7b 6d 61 63 | 72 6f 63 6f 64 65 7d 0a |egin{mac|rocode}.|
|000057c0| 5c 6e 65 77 63 6f 75 6e | 74 5c 4d 75 6c 74 69 43 |\newcoun|t\MultiC|
|000057d0| 6f 75 6e 74 20 5c 6e 65 | 77 63 6f 75 6e 74 5c 4d |ount \ne|wcount\M|
|000057e0| 61 78 43 6f 75 6e 74 0a | 5c 6e 65 77 69 66 5c 69 |axCount.|\newif\i|
|000057f0| 66 53 74 61 72 74 4f 66 | 4c 69 73 74 0a 25 20 20 |fStartOf|List.% |
|00005800| 20 20 5c 65 6e 64 7b 6d | 61 63 72 6f 63 6f 64 65 | \end{m|acrocode|
|00005810| 7d 0a 25 20 20 20 20 5c | 65 6e 64 7b 6d 61 63 72 |}.% \|end{macr|
|00005820| 6f 7d 0a 25 20 20 20 20 | 5c 65 6e 64 7b 6d 61 63 |o}.% |\end{mac|
|00005830| 72 6f 7d 0a 25 20 20 20 | 20 5c 65 6e 64 7b 6d 61 |ro}.% | \end{ma|
|00005840| 63 72 6f 7d 0a 25 0a 25 | 20 20 20 20 5c 62 65 67 |cro}.%.%| \beg|
|00005850| 69 6e 7b 6d 61 63 72 6f | 7d 7b 5c 4d 75 6c 74 69 |in{macro|}{\Multi|
|00005860| 52 65 61 64 7d 0a 25 54 | 68 65 20 70 61 72 61 6d |Read}.%T|he param|
|00005870| 65 74 65 72 20 74 6f 20 | 7c 5c 4d 75 6c 74 69 52 |eter to ||\MultiR|
|00005880| 65 61 64 7c 20 69 73 20 | 74 68 65 20 6e 75 6d 62 |ead| is |the numb|
|00005890| 65 72 20 6f 66 20 63 6f | 6c 75 6d 6e 73 20 74 6f |er of co|lumns to|
|000058a0| 20 72 65 61 64 20 61 74 | 20 61 0a 25 74 69 6d 65 | read at| a.%time|
|000058b0| 2e 20 54 68 69 73 20 63 | 6f 6d 6d 61 6e 64 20 70 |. This c|ommand p|
|000058c0| 61 73 73 65 73 20 63 6f | 6e 74 72 6f 6c 20 74 6f |asses co|ntrol to|
|000058d0| 20 7c 5c 4e 65 78 74 52 | 65 61 64 7c 20 61 66 74 | |\NextR|ead| aft|
|000058e0| 65 72 20 69 6e 69 74 69 | 61 6c 69 7a 69 6e 67 0a |er initi|alizing.|
|000058f0| 25 63 65 72 74 61 69 6e | 20 70 61 72 61 6d 65 74 |%certain| paramet|
|00005900| 65 72 73 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ers..% | \begin|
|00005910| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 5c 64 65 66 |{macroco|de}.\def|
|00005920| 5c 4d 75 6c 74 69 52 65 | 61 64 23 31 7b 25 0a 20 |\MultiRe|ad#1{%. |
|00005930| 20 20 5c 69 66 6e 75 6d | 23 31 3e 30 0a 20 20 20 | \ifnum|#1>0. |
|00005940| 20 20 20 5c 53 65 6c 65 | 63 74 43 52 0a 20 20 20 | \Sele|ctCR. |
|00005950| 20 20 20 5c 4d 61 6b 65 | 45 6d 70 74 79 7b 23 31 | \Make|Empty{#1|
|00005960| 7d 25 0a 20 20 20 20 20 | 20 5c 67 6c 6f 62 61 6c |}%. | \global|
|00005970| 5c 53 74 61 72 74 4f 66 | 4c 69 73 74 74 72 75 65 |\StartOf|Listtrue|
|00005980| 0a 20 20 20 20 20 20 5c | 67 6c 65 74 5c 4e 65 78 |. \|glet\Nex|
|00005990| 74 52 65 61 64 5c 4d 52 | 65 61 64 0a 20 20 20 20 |tRead\MR|ead. |
|000059a0| 20 20 5c 41 6c 6c 6f 77 | 42 6c 61 6e 6b 0a 20 20 | \Allow|Blank. |
|000059b0| 20 20 20 20 5c 67 6c 6f | 62 61 6c 5c 4d 61 78 43 | \glo|bal\MaxC|
|000059c0| 6f 75 6e 74 3d 23 31 0a | 20 20 20 20 20 20 5c 4e |ount=#1.| \N|
|000059d0| 65 78 74 52 65 61 64 0a | 20 20 20 5c 66 69 7d 0a |extRead.| \fi}.|
|000059e0| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 63 |% \en|d{macroc|
|000059f0| 6f 64 65 7d 0a 25 20 20 | 20 20 5c 65 6e 64 7b 6d |ode}.% | \end{m|
|00005a00| 61 63 72 6f 7d 0a 25 0a | 25 20 20 20 20 5c 62 65 |acro}.%.|% \be|
|00005a10| 67 69 6e 7b 6d 61 63 72 | 6f 7d 7b 5c 45 6d 70 74 |gin{macr|o}{\Empt|
|00005a20| 79 63 74 72 7d 0a 25 20 | 20 20 20 5c 62 65 67 69 |yctr}.% | \begi|
|00005a30| 6e 7b 6d 61 63 72 6f 7d | 7b 5c 4d 61 6b 65 45 6d |n{macro}|{\MakeEm|
|00005a40| 70 74 79 7d 0a 25 54 68 | 65 20 63 6f 6d 6d 61 6e |pty}.%Th|e comman|
|00005a50| 64 20 7c 5c 4d 61 6b 65 | 45 6d 70 74 79 7c 20 69 |d |\Make|Empty| i|
|00005a60| 73 20 72 65 71 75 69 72 | 65 64 20 62 79 20 74 68 |s requir|ed by th|
|00005a70| 65 20 70 72 65 2d 70 72 | 6f 5c 2d 63 65 73 73 5c |e pre-pr|o\-cess\|
|00005a80| 2d 69 6e 67 0a 25 6f 66 | 20 65 61 63 68 20 66 69 |-ing.%of| each fi|
|00005a90| 65 6c 64 2e 0a 25 54 68 | 65 20 69 64 65 61 20 69 |eld..%Th|e idea i|
|00005aa0| 73 20 74 68 61 74 20 74 | 68 65 20 63 6f 6d 6d 61 |s that t|he comma|
|00005ab0| 6e 64 20 7c 5c 63 73 6e | 61 6d 65 20 70 72 7c 24 |nd |\csn|ame pr|$|
|00005ac0| 6e 6e 24 7c 5c 65 6e 64 | 63 73 6e 61 6d 65 7c 2c |nn$|\end|csname|,|
|00005ad0| 0a 25 77 68 69 63 68 20 | 77 65 20 77 69 6c 6c 20 |.%which |we will |
|00005ae0| 6c 6f 6f 73 65 6c 79 20 | 63 61 6c 6c 20 7c 5c 70 |loosely |call |\p|
|00005af0| 72 7c 24 6e 6e 24 2c 0a | 25 69 73 20 65 78 65 63 |r|$nn$,.|%is exec|
|00005b00| 75 74 65 64 20 6f 6e 20 | 65 61 63 68 20 66 69 65 |uted on |each fie|
|00005b10| 6c 64 20 69 6e 20 63 6f | 6c 75 6d 6e 20 24 6e 6e |ld in co|lumn $nn|
|00005b20| 24 2e 20 48 6f 77 65 76 | 65 72 2c 20 6d 6f 73 74 |$. Howev|er, most|
|00005b30| 20 6f 66 20 74 68 65 73 | 65 20 63 6f 6d 6d 61 6e | of thes|e comman|
|00005b40| 64 73 0a 25 77 69 6c 6c | 20 62 65 20 75 6e 64 65 |ds.%will| be unde|
|00005b50| 66 69 6e 65 64 2c 20 61 | 6e 64 20 73 6f 20 77 65 |fined, a|nd so we|
|00005b60| 20 65 71 75 61 74 65 20 | 65 61 63 68 20 6f 66 20 | equate |each of |
|00005b70| 74 68 6f 73 65 20 74 68 | 61 74 20 68 61 73 20 6e |those th|at has n|
|00005b80| 6f 74 20 62 65 65 6e 0a | 25 64 65 66 69 6e 65 64 |ot been.|%defined|
|00005b90| 20 74 6f 20 7c 5c 65 6d | 70 74 79 7c 2e 0a 25 20 | to |\em|pty|..% |
|00005ba0| 20 20 20 5c 62 65 67 69 | 6e 7b 6d 61 63 72 6f 63 | \begi|n{macroc|
|00005bb0| 6f 64 65 7d 0a 5c 6e 65 | 77 63 6f 75 6e 74 5c 45 |ode}.\ne|wcount\E|
|00005bc0| 6d 70 74 79 63 74 72 0a | 5c 64 65 66 5c 4d 61 6b |mptyctr.|\def\Mak|
|00005bd0| 65 45 6d 70 74 79 23 31 | 7b 5c 45 6d 70 74 79 63 |eEmpty#1|{\Emptyc|
|00005be0| 74 72 3d 30 0a 20 20 20 | 5c 6c 6f 6f 70 0a 20 20 |tr=0. |\loop. |
|00005bf0| 20 20 20 20 5c 61 64 76 | 61 6e 63 65 5c 45 6d 70 | \adv|ance\Emp|
|00005c00| 74 79 63 74 72 20 62 79 | 31 0a 20 20 20 20 20 20 |tyctr by|1. |
|00005c10| 5c 65 78 70 61 6e 64 61 | 66 74 65 72 5c 69 66 78 |\expanda|fter\ifx|
|00005c20| 5c 63 73 6e 61 6d 65 0a | 20 20 20 20 20 20 20 20 |\csname.| |
|00005c30| 20 70 72 5c 74 68 65 5c | 45 6d 70 74 79 63 74 72 | pr\the\|Emptyctr|
|00005c40| 5c 65 6e 64 63 73 6e 61 | 6d 65 5c 72 65 6c 61 78 |\endcsna|me\relax|
|00005c50| 0a 20 20 20 20 20 20 20 | 20 20 5c 65 78 70 61 6e |. | \expan|
|00005c60| 64 61 66 74 65 72 5c 67 | 6c 65 74 5c 63 73 6e 61 |dafter\g|let\csna|
|00005c70| 6d 65 0a 20 20 20 20 20 | 20 20 20 20 20 20 20 70 |me. | p|
|00005c80| 72 5c 74 68 65 5c 45 6d | 70 74 79 63 74 72 5c 65 |r\the\Em|ptyctr\e|
|00005c90| 6e 64 63 73 6e 61 6d 65 | 5c 65 6d 70 74 79 0a 20 |ndcsname|\empty. |
|00005ca0| 20 20 20 20 20 5c 66 69 | 0a 20 20 20 20 20 20 5c | \fi|. \|
|00005cb0| 69 66 6e 75 6d 5c 45 6d | 70 74 79 63 74 72 3c 23 |ifnum\Em|ptyctr<#|
|00005cc0| 31 0a 20 20 20 5c 72 65 | 70 65 61 74 7d 0a 25 20 |1. \re|peat}.% |
|00005cd0| 20 20 20 5c 65 6e 64 7b | 6d 61 63 72 6f 63 6f 64 | \end{|macrocod|
|00005ce0| 65 7d 0a 25 20 20 20 20 | 5c 65 6e 64 7b 6d 61 63 |e}.% |\end{mac|
|00005cf0| 72 6f 7d 0a 25 20 20 20 | 20 5c 65 6e 64 7b 6d 61 |ro}.% | \end{ma|
|00005d00| 63 72 6f 7d 0a 25 4e 6f | 74 65 20 74 68 61 74 2c |cro}.%No|te that,|
|00005d10| 20 62 65 63 61 75 73 65 | 20 6f 66 20 74 68 65 20 | because| of the |
|00005d20| 77 61 79 20 77 65 20 61 | 72 65 20 61 63 63 65 73 |way we a|re acces|
|00005d30| 73 69 6e 67 20 69 74 20 | 76 69 61 20 7c 5c 63 73 |sing it |via |\cs|
|00005d40| 6e 61 6d 65 7c 2c 0a 25 | 74 68 65 20 66 69 72 73 |name|,.%|the firs|
|00005d50| 74 20 74 69 6d 65 20 7c | 5c 70 72 7c 24 6e 6e 24 |t time ||\pr|$nn$|
|00005d60| 20 69 73 20 65 6e 63 6f | 75 6e 74 65 72 65 64 20 | is enco|untered |
|00005d70| 69 74 20 65 71 75 61 74 | 65 73 20 74 6f 20 7c 5c |it equat|es to |\|
|00005d80| 72 65 6c 61 78 7c 2e 0a | 25 0a 25 20 20 20 20 5c |relax|..|%.% \|
|00005d90| 62 65 67 69 6e 7b 6d 61 | 63 72 6f 7d 7b 5c 50 72 |begin{ma|cro}{\Pr|
|00005da0| 6f 63 65 73 73 7d 0a 25 | 54 68 65 20 63 6f 6d 6d |ocess}.%|The comm|
|00005db0| 61 6e 64 20 7c 5c 50 72 | 6f 63 65 73 73 23 31 23 |and |\Pr|ocess#1#|
|00005dc0| 32 7c 20 64 65 66 69 6e | 65 73 20 7c 5c 70 72 23 |2| defin|es |\pr#|
|00005dd0| 31 7c 20 74 6f 20 6d 65 | 61 6e 20 7c 23 32 7c 2e |1| to me|an |#2|.|
|00005de0| 0a 25 20 20 20 20 5c 62 | 65 67 69 6e 7b 6d 61 63 |.% \b|egin{mac|
|00005df0| 72 6f 63 6f 64 65 7d 0a | 5c 64 65 66 5c 50 72 6f |rocode}.|\def\Pro|
|00005e00| 63 65 73 73 23 31 23 32 | 7b 25 0a 20 20 20 5c 65 |cess#1#2|{%. \e|
|00005e10| 78 70 61 6e 64 61 66 74 | 65 72 5c 64 65 66 5c 63 |xpandaft|er\def\c|
|00005e20| 73 6e 61 6d 65 0a 20 20 | 20 20 20 20 70 72 23 31 |sname. | pr#1|
|00005e30| 5c 65 6e 64 63 73 6e 61 | 6d 65 23 23 31 7b 23 32 |\endcsna|me##1{#2|
|00005e40| 7b 23 23 31 7d 7d 7d 0a | 25 20 20 20 20 5c 65 6e |{##1}}}.|% \en|
|00005e50| 64 7b 6d 61 63 72 6f 63 | 6f 64 65 7d 0a 25 20 20 |d{macroc|ode}.% |
|00005e60| 20 20 5c 65 6e 64 7b 6d | 61 63 72 6f 7d 0a 25 0a | \end{m|acro}.%.|
|00005e70| 25 20 20 20 20 5c 62 65 | 67 69 6e 7b 6d 61 63 72 |% \be|gin{macr|
|00005e80| 6f 7d 7b 5c 4d 61 72 6b | 45 6e 64 7d 0a 25 57 65 |o}{\Mark|End}.%We|
|00005e90| 20 6e 65 65 64 20 74 6f | 20 6b 6e 6f 77 20 68 6f | need to| know ho|
|00005ea0| 77 20 74 68 65 20 6c 61 | 73 74 20 72 6f 77 20 69 |w the la|st row i|
|00005eb0| 73 20 74 6f 20 62 65 20 | 72 65 63 6f 67 6e 69 7a |s to be |recogniz|
|00005ec0| 65 64 2e 20 54 68 65 20 | 64 65 66 61 75 6c 74 20 |ed. The |default |
|00005ed0| 69 73 20 61 6e 0a 25 65 | 6d 70 74 79 20 6c 69 6e |is an.%e|mpty lin|
|00005ee0| 65 20 69 6e 20 74 68 65 | 20 6d 65 72 67 65 20 66 |e in the| merge f|
|00005ef0| 69 6c 65 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ile..% | \begin|
|00005f00| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 5c 64 65 66 |{macroco|de}.\def|
|00005f10| 5c 4d 61 72 6b 45 6e 64 | 23 31 7b 5c 67 64 65 66 |\MarkEnd|#1{\gdef|
|00005f20| 5c 45 6e 64 4d 61 72 6b | 65 72 7b 23 31 7d 7d 0a |\EndMark|er{#1}}.|
|00005f30| 5c 4d 61 72 6b 45 6e 64 | 7b 7d 0a 25 20 20 20 20 |\MarkEnd|{}.% |
|00005f40| 5c 65 6e 64 7b 6d 61 63 | 72 6f 63 6f 64 65 7d 0a |\end{mac|rocode}.|
|00005f50| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 7d |% \en|d{macro}|
|00005f60| 0a 25 0a 25 20 20 20 20 | 5c 62 65 67 69 6e 7b 6d |.%.% |\begin{m|
|00005f70| 61 63 72 6f 7d 7b 5c 4e | 65 78 74 4c 69 6e 65 7d |acro}{\N|extLine}|
|00005f80| 0a 25 20 20 20 20 5c 62 | 65 67 69 6e 7b 6d 61 63 |.% \b|egin{mac|
|00005f90| 72 6f 7d 7b 5c 4e 65 78 | 74 46 69 65 6c 64 7d 0a |ro}{\Nex|tField}.|
|00005fa0| 25 57 65 20 63 6f 6c 6c | 65 63 74 20 65 61 63 68 |%We coll|ect each|
|00005fb0| 20 72 6f 77 20 69 6e 20 | 61 20 74 6f 6b 65 6e 20 | row in |a token |
|00005fc0| 72 65 67 69 73 74 65 72 | 2e 20 54 68 65 20 66 75 |register|. The fu|
|00005fd0| 6c 6c 20 72 6f 77 20 69 | 73 20 61 73 73 65 6d 62 |ll row i|s assemb|
|00005fe0| 6c 65 64 0a 25 69 6e 20 | 7c 5c 4e 65 78 74 4c 69 |led.%in ||\NextLi|
|00005ff0| 6e 65 7c 20 62 65 66 6f | 72 65 20 62 65 69 6e 67 |ne| befo|re being|
|00006000| 20 70 61 73 73 65 64 20 | 62 61 63 6b 20 74 6f 20 | passed |back to |
|00006010| 5c 54 65 58 2e 20 45 61 | 63 68 20 66 69 65 6c 64 |\TeX. Ea|ch field|
|00006020| 20 69 73 0a 25 72 65 61 | 64 20 69 6e 20 7c 5c 54 | is.%rea|d in |\T|
|00006030| 65 6d 70 46 69 65 6c 64 | 7c 20 61 6e 64 20 74 68 |empField|| and th|
|00006040| 65 6e 20 70 6c 61 63 65 | 64 20 74 65 6d 70 6f 72 |en place|d tempor|
|00006050| 61 72 69 6c 79 20 69 6e | 74 6f 0a 25 7c 5c 4e 65 |arily in|to.%|\Ne|
|00006060| 78 74 46 69 65 6c 64 7c | 2e 0a 25 20 20 20 20 5c |xtField||..% \|
|00006070| 62 65 67 69 6e 7b 6d 61 | 63 72 6f 63 6f 64 65 7d |begin{ma|crocode}|
|00006080| 0a 5c 6e 65 77 74 6f 6b | 73 5c 4e 65 78 74 4c 69 |.\newtok|s\NextLi|
|00006090| 6e 65 20 5c 6e 65 77 74 | 6f 6b 73 5c 4e 65 78 74 |ne \newt|oks\Next|
|000060a0| 46 69 65 6c 64 0a 25 20 | 20 20 20 5c 65 6e 64 7b |Field.% | \end{|
|000060b0| 6d 61 63 72 6f 63 6f 64 | 65 7d 0a 25 20 20 20 20 |macrocod|e}.% |
|000060c0| 5c 65 6e 64 7b 6d 61 63 | 72 6f 7d 0a 25 20 20 20 |\end{mac|ro}.% |
|000060d0| 20 5c 65 6e 64 7b 6d 61 | 63 72 6f 7d 0a 25 49 74 | \end{ma|cro}.%It|
|000060e0| 20 69 73 20 6e 6f 74 20 | 6e 65 63 65 73 73 61 72 | is not |necessar|
|000060f0| 79 20 74 6f 20 64 6f 20 | 74 68 69 6e 67 73 20 74 |y to do |things t|
|00006100| 68 69 73 20 77 61 79 3b | 20 7c 5c 65 64 65 66 7c |his way;| |\edef||
|00006110| 20 63 61 6e 20 62 65 20 | 75 73 65 64 0a 25 69 6e | can be |used.%in|
|00006120| 73 74 65 61 64 2c 20 62 | 75 74 20 74 68 61 74 20 |stead, b|ut that |
|00006130| 61 70 70 72 6f 61 63 68 | 20 6d 69 67 68 74 20 65 |approach| might e|
|00006140| 78 70 61 6e 64 20 74 6f | 6b 65 6e 73 20 70 72 65 |xpand to|kens pre|
|00006150| 6d 61 74 75 72 65 6c 79 | 2e 0a 25 0a 25 20 20 20 |maturely|..%.% |
|00006160| 20 5c 62 65 67 69 6e 7b | 6d 61 63 72 6f 7d 7b 5c | \begin{|macro}{\|
|00006170| 41 70 70 65 6e 64 4e 65 | 78 74 46 69 65 6c 64 7d |AppendNe|xtField}|
|00006180| 0a 25 41 66 74 65 72 20 | 74 68 65 20 6e 65 78 74 |.%After |the next|
|00006190| 20 66 69 65 6c 64 20 68 | 61 73 20 62 65 65 6e 20 | field h|as been |
|000061a0| 72 65 61 64 2c 20 69 74 | 20 69 73 20 61 70 70 65 |read, it| is appe|
|000061b0| 6e 64 65 64 20 74 6f 20 | 7c 5c 4e 65 78 74 4c 69 |nded to ||\NextLi|
|000061c0| 6e 65 7c 2e 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ne|..% | \begin|
|000061d0| 7b 6d 61 63 72 6f 63 6f | 64 65 7d 0a 5c 64 65 66 |{macroco|de}.\def|
|000061e0| 5c 41 70 70 65 6e 64 4e | 65 78 74 46 69 65 6c 64 |\AppendN|extField|
|000061f0| 7b 25 0a 20 20 20 5c 67 | 6c 6f 62 61 6c 5c 61 64 |{%. \g|lobal\ad|
|00006200| 76 61 6e 63 65 5c 4d 75 | 6c 74 69 43 6f 75 6e 74 |vance\Mu|ltiCount|
|00006210| 31 0a 20 20 20 5c 4e 65 | 78 74 46 69 65 6c 64 3d |1. \Ne|xtField=|
|00006220| 5c 65 78 70 61 6e 64 61 | 66 74 65 72 7b 5c 54 65 |\expanda|fter{\Te|
|00006230| 6d 70 46 69 65 6c 64 7d | 25 0a 20 20 20 5c 65 64 |mpField}|%. \ed|
|00006240| 65 66 5c 41 70 70 65 6e | 64 7b 5c 4e 65 78 74 4c |ef\Appen|d{\NextL|
|00006250| 69 6e 65 3d 0a 20 20 20 | 20 20 20 7b 5c 74 68 65 |ine=. | {\the|
|00006260| 5c 4e 65 78 74 4c 69 6e | 65 26 5c 63 73 6e 61 6d |\NextLin|e&\csnam|
|00006270| 65 0a 20 20 20 20 20 20 | 20 20 20 70 72 5c 74 68 |e. | pr\th|
|00006280| 65 5c 4d 75 6c 74 69 43 | 6f 75 6e 74 5c 65 6e 64 |e\MultiC|ount\end|
|00006290| 63 73 6e 61 6d 65 0a 20 | 20 20 20 20 20 20 20 20 |csname. | |
|000062a0| 7b 5c 74 68 65 5c 4e 65 | 78 74 46 69 65 6c 64 7d |{\the\Ne|xtField}|
|000062b0| 7d 7d 25 0a 20 20 20 5c | 41 70 70 65 6e 64 7d 0a |}}%. \|Append}.|
|000062c0| 25 20 20 20 20 5c 65 6e | 64 7b 6d 61 63 72 6f 63 |% \en|d{macroc|
|000062d0| 6f 64 65 7d 0a 25 20 20 | 20 20 5c 65 6e 64 7b 6d |ode}.% | \end{m|
|000062e0| 61 63 72 6f 7d 0a 25 0a | 25 20 20 20 20 5c 62 65 |acro}.%.|% \be|
|000062f0| 67 69 6e 7b 6d 61 63 72 | 6f 7d 7b 5c 45 6e 64 4c |gin{macr|o}{\EndL|
|00006300| 69 6e 65 7d 0a 25 20 20 | 20 20 5c 62 65 67 69 6e |ine}.% | \begin|
|00006310| 7b 6d 61 63 72 6f 7d 7b | 5c 46 69 6e 69 73 68 4c |{macro}{|\FinishL|
|00006320| 69 6e 65 7d 0a 25 57 65 | 20 6e 65 65 64 20 74 6f |ine}.%We| need to|
|00006330| 20 69 6e 73 65 72 74 20 | 74 68 65 20 63 6f 72 72 | insert |the corr|
|00006340| 65 63 74 20 65 6e 64 20 | 6d 61 72 6b 65 72 20 61 |ect end |marker a|
|00006350| 66 74 65 72 20 65 61 63 | 68 20 72 6f 77 20 6f 66 |fter eac|h row of|
|00006360| 20 74 68 65 20 74 61 62 | 6c 65 2e 0a 25 54 68 65 | the tab|le..%The|
|00006370| 20 74 6f 6b 65 6e 20 7c | 5c 63 72 7c 20 6d 75 73 | token ||\cr| mus|
|00006380| 74 20 62 65 20 64 69 73 | 67 75 69 73 65 64 20 61 |t be dis|guised a|
|00006390| 20 6c 69 74 74 6c 65 20 | 62 65 66 6f 72 65 20 69 | little |before i|
|000063a0| 74 20 69 73 20 61 63 63 | 65 70 74 61 62 6c 65 0a |t is acc|eptable.|
|000063b0| 25 69 6e 20 61 20 5c 4c | 61 54 65 58 5c 20 64 6f |%in a \L|aTeX\ do|
|000063c0| 63 75 6d 65 6e 74 2e 0a | 25 20 20 20 20 5c 62 65 |cument..|% \be|
|000063d0| 67 69 6e 7b 6d 61 63 72 | 6f 63 6f 64 65 7d 0a 5c |gin{macr|ocode}.\|
|000063e0| 64 65 66 5c 53 65 6c 65 | 63 74 43 52 7b 5c 67 6c |def\Sele|ctCR{\gl|
|000063f0| 65 74 5c 45 6e 64 4c 69 | 6e 65 5c 5c 7d 25 0a 25 |et\EndLi|ne\\}%.%|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.